uGMAR

R package for Gaussian and Student's t mixture autoregression analysis (also available on CRAN)

https://github.com/saviviro/ugmar

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (15.6%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

R package for Gaussian and Student's t mixture autoregression analysis (also available on CRAN)

Basic Info
Statistics
  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • Open Issues: 1
  • Releases: 0
Created about 7 years ago · Last pushed about 1 year ago
Metadata Files
Readme Changelog

README.Rmd

---
output: github_document
---



```{r, include = FALSE}
knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)
```
# uGMAR




uGMAR provides tools for estimating and analyzing Gaussian mixture autoregressive (GMAR), Student's t mixture Autoregressive (StMAR) and Gaussian and Student's t mixture autoregressive (G-StMAR) models, including functions for unconstrained and constrained maximum likelihood estimation of the model parameters, quantile residual based model diagnostics, simulation from the processes, and forecasting.

Installation
------------

You can install the released version of uGMAR from [CRAN](https://CRAN.R-project.org) with:

``` r
install.packages("uGMAR")
```

And the development version from [GitHub](https://github.com/) with:

``` r
# install.packages("devtools")
devtools::install_github("saviviro/uGMAR")
```

Example
-------

This is a basic example how to estimate GSMAR model and further analyze it.. The example data is simulated from a GMAR p=1, M=2 process. The estimation process is computationally demanding and takes advantage of parallel computing.

``` r
## Estimate a GMAR(1, 2) model and examine the estimates
data(simudata, package="uGMAR")
fit <- fitGSMAR(data=simudata, p=1, M=2, model="GMAR", ncalls=10, seeds=1:10)
fit
summary(fit) # Approximate standard errors in brackets
plot(fit)

get_gradient(fit) # The first order condition
get_soc(fit) # The second order condition (eigenvalues of approximated Hessian)
profile_logliks(fit) # Plot the profile log-likelihood functions

## Quantile residual diagnostics
quantile_residual_plot(fit)
diagnostic_plot(fit)
qrt <- quantile_residual_tests(fit)

## Simulate a sample path from the estimated process
sim <- simulate(fit, nsim=100)
plot.ts(sim$sample)

## Forecast future values of the process
predict(fit, n_ahead=10, pi=c(0.95, 0.8))

# Estimate a GMAR(1, 2) model with the autoregressive coefficients restricted
# to be the same in both regimes:
fitr <- fitGSMAR(data=simudata, p=1, M=2, model="GMAR", restricted=TRUE,
                 ncalls=10, seeds=1:10)

# Test with likelihood ratio tests whether the AR parameters are the same in
# both regimes (see also the function 'Wald_test'):
LR_test(fit, fitr)

# Conditional mean and variance plots:
cond_moment_plot(fit, which_moment="mean")
cond_moment_plot(fit, which_moment="variance")

```

References
----------

-   Kalliovirta L., Meitz M. and Saikkonen P. 2015. Gaussian Mixture Autoregressive model for univariate time series. *Journal of Time Series Analysis*, **36**(2), 247-266.
-  Meitz M., Preve D., Saikkonen P. 2023. A mixture autoregressive model based on Student's t-distribution. *Communications in Statistics - Theory and Methods* **52**(2), 499-515.
-  \item Virolainen S. 2022. A mixture autoregressive model based on Gaussian and Student's t-distributions. *Studies in Nonlinear Dynamics & Econometrics*, **26**(4), 559-580.

Owner

  • Login: saviviro
  • Kind: user

GitHub Events

Total
  • Push event: 5
Last Year
  • Push event: 5

Committers

Last synced: over 2 years ago

All Time
  • Total Commits: 329
  • Total Committers: 4
  • Avg Commits per committer: 82.25
  • Development Distribution Score (DDS): 0.517
Past Year
  • Commits: 2
  • Committers: 1
  • Avg Commits per committer: 2.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Virolainen s****o@a****i 159
saviviro s****3@g****m 154
Savi Virolainen s****n@h****i 9
saviviro 4****o 7
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: over 2 years ago

All Time
  • Total issues: 0
  • Total pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Total issue authors: 0
  • Total pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • cran 612 last-month
  • Total docker downloads: 21,613
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 30
  • Total maintainers: 1
cran.r-project.org: uGMAR

Estimate Univariate Gaussian and Student's t Mixture Autoregressive Models

  • Versions: 30
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 612 Last month
  • Docker Downloads: 21,613
Rankings
Downloads: 20.0%
Forks count: 28.8%
Average: 29.1%
Dependent packages count: 29.8%
Stargazers count: 31.7%
Dependent repos count: 35.5%
Maintainers (1)
Last synced: 11 months ago

Dependencies

DESCRIPTION cran
  • R >= 3.4.0 depends
  • Brobdingnag >= 1.2 imports
  • gsl >= 1.9 imports
  • parallel * imports
  • pbapply >= 1.3 imports
  • stats >= 3.3.2 imports
  • knitr * suggests
  • rmarkdown * suggests
  • testthat * suggests