Maximum likelihood estimation in ARMA Models Data: Annual number of lynx trappings in the Mackenzie River District for the period 1821 to 1934. Previously we used the Yule-Walker equations to fit an AR(1) and AR(2) model to the data. In Splus, we find the MLE's using the command arima.mle NOTE: The command arima.mle does not explictly allow for a non-zero mean of the time series. There are two ways for us to account for this, which will be illustrated in the examples: 1. Subtract the mean from the series 2. Tell Splus to estimate a constant term in our model, i.e. x_t = c + phi_1 * x_(t-1) + ... ################ (a) AR(2). We asking Splus to find the MLE, we need to give it a starting "guess" at the estimates. First, do this by subtracting mean. > lynx.ar2mle <- arima.mle(lynx - mean(lynx), model = list(ar=c(.2, .2))) Some output deleted: > lynx.ar2mle Call: arima.mle(x = lynx - mean(lynx), model = list(ar = c(0.2, 0.2))) Method: Maximum Likelihood Model : 2 0 0 Coefficients: AR : 1.15256 -0.60646 Variance-Covariance Matrix: ar(1) ar(2) ar(1) 0.005644742 -0.004049843 ar(2) -0.004049843 0.005644742 Second, use the xreg option to introduce a constant term: > lynx.ar2mlexr <- arima.mle(lynx, model = list(ar=c(.2, .2)), xreg=1) > lynx.ar2mlexr Coefficients: AR : 1.15244 -0.60623 Variance-Covariance Matrix: ar(1) ar(2) ar(1) 0.005647161 -0.004051740 ar(2) -0.004051740 0.005647161 Coeffficients for regressor(s): intercept [1] 1564.778 ######################################## (b) MA(1). > lynx.ma1mle <- arima.mle(lynx - mean(lynx), model = list(ma=.2)) > lynx.ma1mle Coefficients: MA : -0.79335 ################################################### (c) ARMA(1,1). > lynx.arma <- arima.mle(lynx, model = list(ar = .2, ma=.2), xreg=1) > lynx.arma Coefficients: AR : 0.54776 MA : -0.61034 Variance-Covariance Matrix: ar(1) ma(1) ar(1) 0.008222784 0.003866884 ma(1) 0.003866884 0.007371418 Coeffficients for regressor(s): intercept [1] 1587.058