polyChar | R Documentation |
The polyChar function takes an ARIMA model and produces a list of characteristic polynomials for the fitted model. The elements in the list are of class “polynomial”. The terms are auto-regressive (ar), seasonal auto-regressive (sar), regular differences (diff), seasonal differences (s diff), moving average (ma), seasonal moving average (sma), and the constant term.
polyChar(model)
model |
an object of class “arima”. For example, model produced by the Arima() function |
polyChar extracts the coefficients from the ARIMA output and creates a vector of 1 and the coefficient(s) of each term (Example: ma = c(1, coef, coef2)). It then places each vector into a list (finaList). Then using the polynom function from the PolynomF package, polyChar then takes each vector from the list and uses each element within the vector to create a polynomial with ascending degree by the index. Then, an empty polynomial list is created (polyList). The polynomials are assigned an index, named according to their corresponding term in the ARIMA model, and added to polyList. If the term is not present in the model, it defaults to a 1 in the polynomial list. The function then returns the polyList. The list will return a list of 7 elements of the class polynomial.
A list of characteristic polynomials for a given fitted ARIMA model
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.