Re: [R] Estimate Intercept in ARIMA model

2007-08-23 Thread Prof Brian Ripley
This is described on the help page! include.mean: Should the ARIMA model include a mean term? The default is 'TRUE' for undifferenced series, 'FALSE' for differenced ones (where a mean would not affect the fit nor predictions). Further, if 'include.mean' is true, this

[R] Estimate Intercept in ARIMA model

2007-08-23 Thread doublelin15
Hi, All, This is my program ts1.sim <- arima.sim(list(order = c(1,1,0), ar = c(0.7)), n = 200) ts2.sim <- arima.sim(list(order = c(1,1,0), ar = c(0.5)), n = 200) tdata<-ts(c(ts1.sim[-1],ts2.sim[-1])) tre<-c(rep(0,200),rep(1,200)) gender<-rbinom(400,1,.5) x<-matrix(0,2,400) x[1,]<-tre x[2,]<-gen