[R] Incorrect number of dimensions

Sarah ellio184 at umn.edu
Sat Dec 5 19:46:08 CET 2009


I am trying to fit a linear model with seasonal effects but keep getting
'Incorrect number of dimensions'.  I have no idea what this means or how to
fix it.  I am following instructions received from an instructor and it
worked for him, so I assume it has something to do with my data.  Here is my
code:

sed<-ts(data2[,-c(1,2)],start=c(1967,10),end=c(2007,9),freq=12)
ym<-time(sed)
month<-as.factor(sed[,"Period"])
  Error in `[.default`(sed, , "Period") : incorrect number of dimensions

So I am getting the error when I try to designate month as a factor.

Help!
-- 
View this message in context: http://n4.nabble.com/Incorrect-number-of-dimensions-tp949301p949301.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list