error('dates:pop','Input argument %s has to be a dates object with a single element, a string (which can be interpreted as a date) or an integer!',inputname(2))
end
ifischar(p)
p=dates(p);
end
ifisnumeric(p)
idx=find(transpose(1:o.ndat())~=p);
o.time=o.time(idx,:);
ifnargin>1
o.pop_(p);
else
if~isequal(o.freq,p.freq)
error('dates:pop','Inputs must have common frequency!')
end
ifp.length()>1
error('dates:pop','dates to be removed must have one element!')
error('dates:pop','Input argument %s has to be a dates object with a single element, a string (which can be interpreted as a date) or an integer!',inputname(2))
end
ifischar(p)
p=dates(p);
end
ifisnumeric(p)
idx=find(transpose(1:o.ndat())~=p);
o.time=o.time(idx,:);
else
if~isequal(o.freq,p.freq)
error('dates:pop','Inputs must have common frequency!')
end
ifp.length()>1
error('dates:pop','dates to be removed must have one element!')