search for: cash_fit

Displaying 1 result from an estimated 1 matches for "cash_fit".

2011 Oct 03
2
rolling regression
...year data set organized in a ts matrix. The matrix has 5 columns; cash_ret, epy1, ism1, spread1, unemp1 I have been able to come up with the following based on previous help threads. It seems to work fine. The trouble is I get regression coefficients but need the immediate next period forecast. cash_fit= rollapply(cash_data, width=60, function(x) coef(lm(cash_ret~epy1+ism1+spread1+unemp1, data = as.data.frame(x))), by.column=FALSE, align="right"); cash_fit I tried to replace "coef" above to "predict" but I get a whole bunch of results too big to be displayed. I...