partialAR (version 1.0.3)

likelihood_ratio.par: Computes log likelihood ratio for partial autoregressive model

Description

Computes the log likelihood ratio for the partially autoregressive model.

First, a fit is performed for the specified null model. Then, a fit is performed for the alternative model that the sequence is partially autoregressive. The likelihood scores are computed for both models, and the log likelihood ratio is returned.

Usage

likelihood_ratio.par(X, robust = FALSE, null_model = c("rw", "ar1"), 
  opt_method = c("css", "fkf", "ss"), nu = par.nu.default())

Arguments

X
The numeric vector or zoo vector to which the partially autoregressive model is being fit.
robust
If TRUE, then errors are assumed to follow a t-distribution with nu degrees of freedom. If FALSE, then errors are assumed to follow a normal distribution. Default: FALSE
null_model
Specifies the null hypothesis:
  • "rw"
{Pure random walk (e.g., sigma_M = 0)} "ar1" {Pure autoregressive (e.g., sigma_R = 0)}

Value

  • A numeric value representing the log likelihood ratio

item

  • opt_method
  • nu

itemize

  • "ss"Steady-state Kalman filter with normally distributed errors
  • "css"Steady-state Kalman filter with normally distributed errors, coded in C++
  • "fkf"Traditional Kalman filter of thefkfpackage

code

TRUE

References

Clegg, Matthew. Modeling Time Series with Both Permanent and Transient Components using the Partially Autoregressive Model. Available at SSRN: http://ssrn.com/abstract=2556957

See Also

fit.par