Hi all, I've got a time series object (xts) called table. Table contains closing price and volume for each market day of 2009 on a given equity.
I'd like to get another xts object, say table2, that contains for each market day holds the close of that day minus the close of the day before and the volume of that day minus the volume of the day before. So table2 <- table[x,] - table[(x-1),] But I can't quit get the syntax, any help would be appreciated. Nick [[alternative HTML version deleted]] ______________________________________________ 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.