cross_validate: Time series cross-validation with DP-INAR model predictions

Description Usage Arguments Value

View source: R/dpinar.R

Description

Obtain predictions of a given test set and the mean absolute errors

Usage

1
2
3
4
cross_validate(time_series, p = 1, h = 1, training_epoch = NULL,
  prior = list(a_alpha = NULL, a0_tau = NULL, b0_tau = NULL, a0_G0 =
  NULL, b0_G0 = NULL, lambda_max = NULL), burn_in = 10^3,
  chain_length = 10^4, random_seed = 1761, verbose = TRUE)

Arguments

time_series

A univariate time series.

h

Number of steps ahead to be predicted.

training_epoch

The last observation of the first training set.

prior

List of prior hyperparameters where:

a_alpha

Hyperparameters of the thinning component.

a0_tau, b0_tau

Hyperparameters of the concentration parameter Gamma prior.

a0_G0, b0_G0

Base measure hyperparameters.

lambda_max

Hyperparameter of the uniform distribution that minimizes the corresponding D-KL.

burn_in

Number of iterations for the "burn-in" period which are discarded in the chain.

chain_length

Number of iterations of the chain.

random_seed

Value of the random seed generator.

verbose

If TRUE log info is provided.

Value

A list with the following elements:

est

Predictions of the test set.

mae

Mean Absolute Error of the test set predictions.


bayesianfactory/dpinar documentation built on July 18, 2019, 1:27 a.m.