Description Usage Arguments Details Value References See Also Examples

`LR_test`

performs a likelihood ratio test for a GMAR, StMAR, or G-StMAR model.

1 | ```
LR_test(gsmar1, gsmar2)
``` |

`gsmar1` |
an object of class |

`gsmar2` |
an object of class |

Performs a likelihood ratio test, testing the null hypothesis that the true parameter value lies
in the constrained parameter space specified by constraints imposed to the model `gsmar2`

.
Under the null, the test statistic is asymptotically *χ^2*-distributed with *k* degrees of freedom,
*k* being the difference in the dimensions of the unconstrained and constrained parameter spaces.

Note that this function does **not** verify that the two models are actually nested. Notably, GSMAR models
with different autoregressive orders are not nested, whereas testing models with different numbers of regimes
induce an identification problem and thereby unreliable test results (see the discussion related to Theorem 2
in Virolainen, 2021).

A list with class "htest" containing the following components:

`statistic` |
the value of the likelihood ratio statistics. |

`parameter` |
the degrees of freedom of the likelihood ratio statistic. |

`p.value` |
the p-value of the test. |

`alternative` |
a character string describing the alternative hypothesis. |

`method` |
a character string indicating the type of the test (likelihood ratio test). |

`data.name` |
a character string giving the names of the supplied models, gsmar1 and gsmar2. |

`gsmar1` |
the supplied argument gsmar1 |

`gsmar2` |
the supplied argument gsmar2 |

Kalliovirta L., Meitz M. and Saikkonen P. 2015. Gaussian Mixture Autoregressive model for univariate time series.

*Journal of Time Series Analysis*,**36**, 247-266.Meitz M., Preve D., Saikkonen P. 2021. A mixture autoregressive model based on Student's t-distribution.

*Communications in Statistics - Theory and Methods*, doi: 10.1080/03610926.2021.1916531Virolainen S. 2021. A mixture autoregressive model based on Gaussian and Student's t-distributions. Studies in Nonlinear Dynamics & Econometrics, doi: 10.1515/snde-2020-0060

`Wald_test`

, `fitGSMAR`

, `GSMAR`

, `diagnostic_plot`

,
`profile_logliks`

, `quantile_residual_tests`

, `cond_moment_plot`

1 2 3 4 5 6 7 8 9 10 11 | ```
# GMAR p=1, M=2 model:
fit12 <- fitGSMAR(simudata, p=1, M=2, model="GMAR", ncalls=1, seeds=1)
# GMAR p=1, M=2 model with AR parameters restricted to be the same in both
# regimes:
fit12r <- fitGSMAR(simudata, p=1, M=2, model="GMAR", restricted=TRUE,
ncalls=1, seeds=1)
# Test with likelihood ratio test whether the AR parameters are the same in
# both regimes:
LR_test(fit12, fit12r)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.