Metrics: MSE and Success Ratio of Forecasts

Description Usage Arguments Value

Description

This function calculates mean squared error (MSE) and the success ratio of a given set of forecasts.

Usage

1
Metrics(pred=NULL, true=NULL, h=0)

Arguments

pred

vector of forecasts.

true

vector of true values.

h

forecasting horizon used in making the forecasts. Default is 0.

Value

This function returns the same outputs as does the maeforecast function. More specifically, it returns a list containing the following objects:

Forecasts

data matrix, containing the point forecasts, realized values, forecast errors, signs of the forecasts and realized values, and success in predicting the signs.

MSE

numeric, mean squred error of the point forecasts.

SRatio

numeric, success ratio of the point forecasts. Success is claimed when the point forecasts and realized values have the same sign.


google-trends-v1/gtm documentation built on June 5, 2019, 5:13 p.m.