com.cloudera.sparkts.models

ARIMA

object ARIMA

ARIMA models allow modeling timeseries as a function of prior values of the series (i.e. autoregressive terms) and a moving average of prior error terms. ARIMA models are traditionally specified as ARIMA(p, d, q), where p is the autoregressive order, d is the differencing order, and q is the moving average order. Using the backshift (aka lag operator) B, which when applied to a Y returns the prior value, the ARIMA model can be specified as Y_t = c + \sum_{i=1}p \phi_i*Bi*Y_t + \sum_{i=1}q \theta_i*Bi*\epsilon_t + \epsilon_t where Y_i has been differenced as appropriate according to order d See https://en.wikipedia.org/wiki/Autoregressive_integrated_moving_average for more information on ARIMA. See https://en.wikipedia.org/wiki/Order_of_integration for more information on differencing integrated time series.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. ARIMA
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def autoFit(ts: Vector, maxP: Int = 5, maxD: Int = 2, maxQ: Int = 5): ARIMAModel

    Utility function to help in fitting an automatically selected ARIMA model based on approximate Akaike Information Criterion (AIC) values.

    Utility function to help in fitting an automatically selected ARIMA model based on approximate Akaike Information Criterion (AIC) values. The model search is based on the heuristic developed by Hyndman and Khandakar (2008) and described in http://www.jstatsoft .org/v27/i03/paper. In contrast to the algorithm in the paper, we use an approximation to the AIC, rather than an exact value. Note that if the maximum differencing order provided does not suffice to induce stationarity, the function returns a failure, with the appropriate message. Additionally, note that the heuristic only considers models that have parameters satisfying the stationarity/invertibility constraints. Finally, note that our algorithm is slightly more lenient than the original heuristic. For example, the original heuristic rejects models with parameters "close" to violating stationarity/invertibility. We only reject those that actually violate it.

    This functionality is even less mature than some of the other model fitting functions here, so use it with caution.

    ts

    time series to which to automatically fit an ARIMA model

    maxP

    limit for the AR order

    maxD

    limit for differencing order

    maxQ

    limit for the MA order

    returns

    an ARIMAModel

  8. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  10. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  11. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  12. def fitModel(p: Int, d: Int, q: Int, ts: Vector, includeIntercept: Boolean = true, method: String = "css-cgd", userInitParams: Array[Double] = null): ARIMAModel

    Given a time series, fit a non-seasonal ARIMA model of order (p, d, q), where p represents the autoregression terms, d represents the order of differencing, and q moving average error terms.

    Given a time series, fit a non-seasonal ARIMA model of order (p, d, q), where p represents the autoregression terms, d represents the order of differencing, and q moving average error terms. If includeIntercept is true, the model is fitted with an intercept. In order to select the appropriate order of the model, users are advised to inspect ACF and PACF plots, or compare the values of the objective function. Finally, while the current implementation of fitModel verifies that parameters fit stationarity and invertibility requirements, there is currently no function to transform them if they do not. It is up to the user to make these changes as appropriate (or select a different model specification)

    p

    autoregressive order

    d

    differencing order

    q

    moving average order

    ts

    time series to which to fit an ARIMA(p, d, q) model

    includeIntercept

    if true the model is fit with an intercept term. Default is true

    method

    objective function and optimization method, current options are 'css-bobyqa', and 'css-cgd'. Both optimize the log likelihood in terms of the conditional sum of squares. The first uses BOBYQA for optimization, while the second uses conjugate gradient descent. Default is 'css-cgd'

    userInitParams

    A set of user provided initial parameters for optimization. If null (default), initialized using Hannan-Rissanen algorithm. If provided, order of parameter should be: intercept term, AR parameters (in increasing order of lag), MA parameters (in increasing order of lag)

  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  16. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  17. final def notify(): Unit

    Definition Classes
    AnyRef
  18. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  19. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  20. def toString(): String

    Definition Classes
    AnyRef → Any
  21. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  22. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped