calc_scores: Calculate various scoring rules for a Time Series Dataset

Description Usage Arguments Details Value

View source: R/calc_scores.R

Description

For each series in dataset, point and interval forecasting performance are evaluated for all methods in methods of ts_forec with regard to MASE, sMAPE, MSIS, Spread, Coverage and Upper coverage.

Usage

1
calc_scores(dataset, parallel = FALSE, num.cores = 2)

Arguments

dataset

the list containing the series. See details for the required format.

parallel

logical. If TRUE then the calculations are conducted in parallel.

num.cores

the specified amount of parallel processes to be used if parallel = TRUE.

Details

dataset must be a list with each element having the following format:

x

a time series object ts with the historical data.

h

the amount of future time steps to forecast.

f

a matrix with F rows and n columns. Each row contains the fitted values of each method in methods.

ff

a matrix with F rows and h columns. Each row contains the forecasts of each method in methods.

lower

a list with each element being the matrix of lower bounds for certain confidence level.

upper

a list with each element being the matrix of upper bounds for certain confidence level.

Value

A list with the elements having the following structure

MASE

a matrix with F rows and h columns. Each row contains the MASE scores of each method in methods. Each column represents the MASE for the j-step point forecasts, where j=1,...,h.

sMAPE

a matrix with F rows and h columns. Each element in the matrix denotes the sMAPE values.

MSIS

a list with each element being a matrix for certain confidence level in level. The matrix contains the MSIS values in corresponding forecasting horizon for each method.

Spread

a list with each element being a matrix for certain confidence level in level. The matrix contains the Spread values in corresponding forecasting horizon for each method.

IfInn

a list with each element being a matrix for certain confidence level in level. Each element in the matrix measures if the true value lies inside the prediction interval.

IfInu

a list with each element being a matrix for certain confidence level in level. Each element in the matrix measures if the true value is not larger than the upper bound of the prediction interval.


xqnwang/fuma documentation built on May 29, 2021, 6:38 a.m.