assert_forecast_type: Assert that forecast type is as expected

View source: R/get_-functions.R

assert_forecast_typeR Documentation

Assert that forecast type is as expected

Description

Assert that forecast type is as expected

Usage

assert_forecast_type(data, actual = get_forecast_type(data), desired = NULL)

Arguments

data

A forecast object as produced by as_forecast().

actual

The actual forecast type of the data

desired

The desired forecast type of the data

Value

Returns NULL invisibly if the assertion was successful and throws an error otherwise.


epiforecasts/scoringutils documentation built on April 23, 2024, 4:56 p.m.