Hi, I am quite new to R and would appreciate some guidance, if possible. I have imported a csv file: spread <- read.csv("Spread.csv") I get the following error when I try to run adf.test:> adf.test(spread,alternative = c("stationary", "explosive"),0)Error in embed(y, k) : 'x' is not a vector or matrix Why is this? -- View this message in context: http://www.nabble.com/Using-ADF.Test-tp23940824p23940824.html Sent from the R help mailing list archive at Nabble.com.
ehxpieterse wrote:> > Hi, > > I am quite new to R and would appreciate some guidance, if possible. > > I have imported a csv file: spread <- read.csv("Spread.csv") > > I get the following error when I try to run adf.test: >> adf.test(spread,alternative = c("stationary", "explosive"),0) > Error in embed(y, k) : 'x' is not a vector or matrix > > Why is this? >What does class(spread) give? You should try as.vector(spread) and see what happens -- View this message in context: http://www.nabble.com/Using-ADF.Test-tp23940824p23959465.html Sent from the R help mailing list archive at Nabble.com.