In a data.frame (or data.table), I would like to "fill forward" NAs with the closest previous non-NA value. A simple example, using vectors (instead of a data.frame) 开发者_开发百科is the fo
I\'m studying some yahoo finance data via quantmod. How would I determine not only the Max and Min price over a rolling window of data, but also the exact Timestamp of those highs and lows? I have tr
Dear R user community, I have many data.frames in a list, as follows (only one data.frame in the list of 21 shown for convenience):
I have a CSV file with timestamps and certain event-types which happened at this time. What I want is count the number of occurences of certain event-types in 6-minutes intervals.
I have the following time series > y<- xts(1:10, Sys.Date()+1:10) > y[c(1,2,5,9,10)] <- NA > y
I开发者_如何学运维 thought Adding Points, Legends and Text to plots using xts objects would have the answer to this question, but apparently not...
I have a zoo object called pp with daily data and 77 columns that looks like this: X02R X03N X04K X04N X04R X06I X06N X08J X08P X09O X11O X12L X14N X15G X16K(...)
I have hundreds of csv files (zoo objects in R) with 2 columns: \"Index\",\"pp\" 1951-01-01,22.9 1951-01-02,4.3
I have two multivariate time series x and y, both covering approximately the same range in time (one starts two years before the other, but they end on the same date). Both series have missing observa
Suppose I have two \'zoo\' vectors, of equal length, with the same indices for both. Is there a simple function that allows me to take the average开发者_如何学编程 of both, by date (index)?