Just learning so excuse me if I'm being too basic here. But I'm wondering how should I know that as.ts would be needed for lag ? Is there a thought process or way to inspect that I should have gone through to know that log would work on y[,5] but lag would not work on [,5] ?
Is the general rule that lag is not in the base package and therefore would not work ? Thanks for the comments -- View this message in context: http://r.789695.n4.nabble.com/Log-difference-in-a-dataframe-column-tp3221225p3224478.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.