[R] Loops
Fred
christoph_wegener at gmx.de
Thu Sep 15 10:23:20 CEST 2011
Thank you so much!
foreL<-8
b0f<-matrix(nrow=9, ncol=foreL)
ct<-1 ### use this as the index of b0f
for(ar.ord in 1:3){
for(ma.ord in 1:3){
b0f[ct,]<-c(predict(arima(para_qtr[1:(n-8),1],order=c(ar.ord,1,ma.ord)),
n.ahead=foreL)$pred)
ct<-ct+1 ### increment the counter
}
}
this one works! Best regards!
--
View this message in context: http://r.789695.n4.nabble.com/Loops-tp3814162p3814971.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list