r - Can I make a time series work with date objects rather than integers? -



r - Can I make a time series work with date objects rather than integers? -

i have time series info i'm trying analyse in r. provided csv excel, subsequently read data.frame all. let's has 2 columns: all$date , all$people, representing count of people on particular date. frequency hence daily.

being excel, dates integers representing number of days since 1900-01-01. read info people = ts(all$people, start=c(all$date[1], 1), frequency=365); gives silly start value of 40000 because info starts in 2006. start parameter doesn't take date object, according ?ts, can't utilize as.date():

ts - ... start: time of first observation. either single number or vector of 2 integers, specify natural time unit , (1-based) number of samples time unit. see examples utilize of sec form.

i of course of study set start=1, it's bit painful figure out season we're in when plot tells me interesting things happening around day 2100. (to clear, setting frequency=365 tell me year we're in, isn't useful more precise dates). there useful way of expressing date in ts in human-readable form don't have maintain calling as.date() understand when interesting features happening?

r date time-series

Comments

Popular posts from this blog

xslt - DocBook 5 to PDF transform failing with error: "fo:flow" is missing child elements. Required content model: marker* -

mediawiki - How do I insert tables inside infoboxes on Wikia pages? -

Local Service User Logged into Windows -