[R] simple ts() object question

StatWM wmusial at gmx.de
Sun Sep 5 06:08:09 CEST 2010


Dear Community,

say, I have an annual ts() object sampled from 1960 to 1969 like:

ta<-ts(1:10, start=1960, frequency=1)

How can I extract the value from the year 1965?

I mean, not by:

ta[6]

but by something like:
 
ta[1965]

where I'm directly referring to the year of the observation?

Thank you in advance!

-- 
View this message in context: http://r.789695.n4.nabble.com/simple-ts-object-question-tp2527085p2527085.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list