Computation of the exact Expected Information Matrix of
the Autoregressive process of order-
AR1EIM(x = NULL, var.arg = NULL, p.drift = NULL,
WNsd = NULL, ARcoeff1 = NULL, eps.porat = 1e-2)
A vector of quantiles. The gaussian time series for which the EIMs are computed.
If multiple time series are being analyzed, then x
must be
a matrix where each column allocates a response.
That is, the number of columns (denoted as
Logical. Same as with AR1
.
A numeric vector with the scaled mean(s) (commonly referred as drift) of the AR process(es) in turn. Its length matches the number of responses.
Matrices.
The standard deviation of the white noise, and the
correlation (coefficient) of the AR(
That is, the dimension for each matrix is
A very small positive number to test whether the standar deviation
(WNsd
) is close enough to its value estimated in this function.
See below for further details.
An array of dimension
This array stores the EIMs calculated from the joint density as
a function of
Nevertheless, note that, under the VGAM/VGLM approach, the EIMs
must be correspondingly calculated in terms of the linear
predictors,
For large enough
This relationsihip is internally considered if a proper value
of AR1EIM
, this is done by checking
the difference between the internally estimated variances and the
entered ones at WNsd
.
If this difference is less than
eps.porat
at some iteration, say at iteration AR1EIM
takes
Finally, note that the rate of convergence reasonably decreases if
the asymptotic relationship
See Porat and Friedlander (1986) for full details on the asymptotic behaviour of the algorithm.
Arguments WNsd
, and ARcoeff1
are matrices of dimension
This function implements the algorithm of Porat and Friedlander (1986) to recursively compute the exact expected information matrix (EIM) of Gaussian time series with stationary random components.
By default, when the VGLM/VGAM family function
AR1
is used to fit an AR(vglm
, Fisher scoring is executed using
the approximate EIM for the AR process. However, this model
can also be fitted using the exact EIMs computed by
AR1EIM
.
Given
AR1
for further details on this).
Consequently, for each observation
and
As for the off-diagonal elements, one has the usual entries, i.e.,
If var.arg = FALSE
, then
Once these expected values are internally computed, they are returned
in an array of dimension
AR1EIM
handles multiple time series, say
the bandwith form, as per required by
AR1
.
Porat, B. and Friedlander, B. (1986) Computation of the Exact Information Matrix of Gaussian Time Series with Stationary Random Components. IEEE Transactions on Acoustics, Speech, and Signal Processing, 54(1), 118--130.
AR1
.
# NOT RUN {
set.seed(1)
nn <- 500
ARcoeff1 <- c(0.3, 0.25) # Will be recycled.
WNsd <- c(exp(1), exp(1.5)) # Will be recycled.
p.drift <- c(0, 0) # Zero-mean gaussian time series.
### Generate two (zero-mean) AR(1) processes ###
ts1 <- p.drift[1]/(1 - ARcoeff1[1]) +
arima.sim(model = list(ar = ARcoeff1[1]), n = nn,
sd = WNsd[1])
ts2 <- p.drift[2]/(1 - ARcoeff1[2]) +
arima.sim(model = list(ar = ARcoeff1[2]), n = nn,
sd = WNsd[2])
ARdata <- matrix(cbind(ts1, ts2), ncol = 2)
### Compute the exact EIMs: TWO responses. ###
ExactEIM <- AR1EIM(x = ARdata, var.arg = FALSE, p.drift = p.drift,
WNsd = WNsd, ARcoeff1 = ARcoeff1)
### For response 1:
head(ExactEIM[, 1 ,]) # NOTICE THAT THIS IS A (nn x 6) MATRIX!
### For response 2:
head(ExactEIM[, 2 ,]) # NOTICE THAT THIS IS A (nn x 6) MATRIX!
# }
Run the code above in your browser using DataLab