search for: indexat

Displaying 2 results from an estimated 2 matches for "indexat".

Did you mean: indexa
2012 Nov 10
2
For loop question
I have this code: IEF <- to.monthly(IEF, indexAt="endof") SPY <- to.monthly(SPY, indexAt="endof") I would like to use a for loop instead of separate entries, so the only code that needs to be modified is the list of symbols. symbols <- c("IEF", "SPY") for(symbol in symbols) { symbol <- to.m...
2010 Apr 11
0
converting a ts object to an xts object
...rterly series. I know that I could use "aggregate", but I am interested in the to.quarterly conversion, please. Here is my example: > str(ibm$ts) Time-Series [1:144] from 1998 to 2010: 43.7 46.3 46 51.4 52.2 ... > tsp(ibm$ts) [1] 1998.000 2009.917 12.000 > to.quarterly(ibm$ts,indexAt='yearqtr') Error in attr(x, "tsp") <- value : invalid time series parameters specified Any suggestions would be much appreciated. Thanks, Erin -- Erin Hodgess Associate Professor Department of Computer and Mathematical Sciences University of Houston - Downtown mailto: e...