normalize_probs: Normalize probabilistic predictions

Description Usage Arguments Value See Also Examples

View source: R/normalize_probs.R

Description

Normalizes all probabilistic predictions so that the cumulative probability for a target sums to 1.

Usage

1
normalize_probs(entry, ignore_invalid = FALSE)

Arguments

entry

A verified entry data.frame with columns location, target, type, unit, bin_start_incl, bin_end_incl, and value.

ignore_invalid

logical; if FALSE all location/target combinations have probabilities normalized: if TRUE location/target combinations with probabilities summing to < 0.9 or > 1.1 are not normalized. Should be TRUE and run in combination with remove_invalid if run on an entry prior to scoring.

Value

An entry data.frame with normalized probabilities

See Also

verify_entry remove_invalid

Examples

1
norm_entry <- normalize_probs(full_entry)

jarad/FluSight documentation built on Oct. 24, 2020, 9:58 p.m.