New time series and forecasting functions have been added to Sybase IQ. These functions are available only with RAP – The Trading Edition® Enterprise.
Like all time series SQL functions, the new functions call two libraries: the IMSL C Stat, and IMSL C Math, integrated third-party libraries. Provided by Visual Numerics, these libraries contain C functions for time series and forecasting, and form part of the Sybase IQ scalar and aggregate UDF infrastructure. Sybase IQ automatically loads the IMSL libraries as needed when you call a valid function for time series and forecasting analysis.
The new aggregate time series SQL functions are:
TS_AUTO_ARIMA Determines parameters of a multiplicative seasonal autoregressive integrated moving average (ARIMA) model, and produces forecasts that incorporate the effects of outliers with effects that persist beyond the end of the time series.
TS_AUTO_ARIMA_OUTLIER Like the TS_AUTO_ARIMA aggregate function, TS_AUTO_ARIMA_OUTLIER accepts an input time series and automatically determines the parameters of an ARIMA model. However, whereas TS_AUTO_ARIMA uses the ARIMA model to forecast values beyond the set of inputs, TS_AUTO_ARIMA uses the ARIMA model to identify statistical outliers in the input time series, and returns the outlier type of each one.
TS_GARCH Used to analyze and forecast volatility in time series data. TS_GARCH computes the estimates of the parameters of a GARCH(p, q) model. GARCH (generalized autoregressive conditional heteroskedasticity) is a generalized model of ARCH; the ARCH computation relates the error variance to the square of a previous period's error.
These scalar functions support the TS_AUTO_ARMA function:
TS_AUTO_ARIMA_RESULT_AIC Retrieves the Akaike's Information Criterion (AIC) output parameter produced by TS_AUTO_ARIMA.
TS_AUTO_ARIMA_RESULT_AICC Retrieves the corrected AIC (AICC) output parameter produced by TS_AUTO_ARIMA.
TS_AUTO_ARIMA_RESULT_BIC Retrieves the Bayesian Information Criterion (BIC) output parameter produced by TS_AUTO_ARIMA.
TS_AUTO_ARIMA_RESULT_FORECAST_VALUE Retrieves the forecasted values for the original input series produced by TS_AUTO_ARIMA.
TS_AUTO_ARIMA_RESULT_FORECAST_ERROR Retrieves the forecasted standard error values for the original input series produced by TS_AUTO_ARIMA.
TS_AUTO_ARIMA_RESULT_MODEL_P Retrieves the p value produced by TS_AUTO_ARIMA when computing the ARIMA model description.
TS_AUTO_ARIMA_RESULT_MODEL_Q Retrieves the q value produced by TS_AUTO_ARIMA when computing the ARIMA model description.
TS_AUTO_ARIMA_RESULT_MODEL_S Retrieves the s value produced by TS_AUTO_ARIMA when computing the ARIMA model description.
TS_AUTO_ARIMA_RESULT_MODEL_D Retrieves the d value produced by TS_AUTO_ARIMA when computing the ARIMA model description.
TS_AUTO_ARIMA_RESULT_RESIDUAL_SIGMA Retrieves the residual standard error of the outlier-free data points.
TS_INT_ARRAY Constructs a logical array of constant integer values encoded as a varbinary value.
TS_INT_ARRAY also supports the TS_AUTO_ARIMA_OUTLIER aggregate function.
These scalar functions support the TS_GARCH function:
TS_DOUBLE_ARRAY Constructs a logical array consisting of 3 –10 constant double-precision floating-point values, and returns a single varbinary value.
TS_GARCH_RESULT_A Retrieves the log-likelihood output parameter, A, produced by the TS_GARCH aggregate function.
TS_GARCH_RESULT_AIC Retrieves the Akaike’s Information Criterion output parameter (AIC) produced by the TS_GARCH aggregate function.
TS_GARCH_RESULT_USER Accesses each element in the logical array that describes the GARCH(p,q) model.
See the Time Series Guide for detailed information on each of these functions.
For reference information on the IMSL C functions, see IMSL Numerical Library User’s Guide: Volume 2 of 2 C Stat Library.