logs_hhh4sims: Simulation-Based Logarithmic Score Using 'dhhh4sims'

logs_hhh4simsR Documentation

Simulation-Based Logarithmic Score Using dhhh4sims

Description

The function logs_hhh4sims computes the logarithmic score of the forecast distributions based on a surveillance::hhh4() model and simulations (sims) thereof. The forecast distributions are obtained via dhhh4sims() as sequential mixtures of negative binomial (or Poisson) distributions, which is different from the kernel density estimation approach employed in scores_sample().

Usage

logs_hhh4sims(observed = NULL, sims, model)

Arguments

observed

a vector or matrix of observed counts during the simulation period. By default (NULL), this is taken from attr(sims, "stsObserved").

sims

a "hhh4sims" object from surveillance::simulate.hhh4().

model

the surveillance::hhh4() fit underlying sims.

Value

a vector or matrix of log-scores for the observed counts.

Author(s)

Sebastian Meyer

See Also

scores_sample() for an alternative approach of calculating the logarithmic score from simulation-based forecasts


HIDDA/forecasting documentation built on Jan. 11, 2024, 1:11 a.m.