# SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.stats.evt.timeseries

## Class MARMAModel

• Direct Known Subclasses:
MARModel, MMAModel

public class MARMAModel
extends Object
Simulation of max autoregressive moving average processes, i.e., MARMA(p, q) processes. That is, $X_k = \max(\phi_1 X_{k-1}, \phi_2 X_{k-2}, ..., \phi_p X_{k-p}, \epsilon_k, \theta_1 \epsilon_{k-1}, \theta_2 \epsilon_{k-2}, ..., \theta_q \epsilon_{k-q})$ where $$\phi_i$$'s are AR coefficients, $$\theta_i$$'s are MA coefficients, $$\epsilon_i$$'s are innovations generated by a GEV distribution.

The R equivalent function is evd::marma.

• ### Constructor Summary

Constructors
Constructor and Description
MARMAModel(double[] AR, double[] MA)
Create an instance with the AR and MA coefficients, using FrechetDistribution as the GEV distribution.
MARMAModel(double[] AR, double[] MA, UnivariateEVD dist)
Create an instance with the AR and MA coefficients, and a GEV distribution for generating innovations.
MARMAModel(UnivariateEVD dist)
Create an instance with a given GEV distribution for generating innovations.
• ### Method Summary

All Methods
Modifier and Type Method and Description
double[] AR()
Get the AR coefficients.
UnivariateEVD getDistribution()
Get the univariate extreme value distribution for generating innovations.
double[] MA()
Get the MA coefficients.
int p()
Get the number of AR terms.
int q()
Get the number of MA terms.
• ### Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
• ### Constructor Detail

• #### MARMAModel

public MARMAModel(UnivariateEVD dist)
Create an instance with a given GEV distribution for generating innovations.
Parameters:
dist - the GEV distribution
• #### MARMAModel

public MARMAModel(double[] AR,
double[] MA)
Create an instance with the AR and MA coefficients, using FrechetDistribution as the GEV distribution.
Parameters:
AR - the AR coefficients $$\phi_i$$
MA - the MA coefficients $$\theta_i$$
• #### MARMAModel

public MARMAModel(double[] AR,
double[] MA,
UnivariateEVD dist)
Create an instance with the AR and MA coefficients, and a GEV distribution for generating innovations.
Parameters:
AR - the AR coefficients $$\phi_i$$
MA - the MA coefficients $$\theta_i$$
dist - the GEV distribution
• ### Method Detail

• #### getDistribution

public UnivariateEVD getDistribution()
Get the univariate extreme value distribution for generating innovations.
Returns:
the innovation distribution
• #### p

public int p()
Get the number of AR terms.
Returns:
the number of AR terms
• #### q

public int q()
Get the number of MA terms.
Returns:
the number of MA terms
• #### AR

public double[] AR()
Get the AR coefficients.
Returns:
the AR coefficients
• #### MA

public double[] MA()
Get the MA coefficients.
Returns:
the MA coefficients