EnsRps: Calculate the ensemble-adjusted Ranked Probability Score...

Description Usage Arguments Details Value See Also Examples

View source: R/EnsRps.R

Description

Calculate the ensemble-adjusted Ranked Probability Score (RPS) for categorical forecasts

Usage

1
2
3
EnsRps(ens, obs, R.new = NA, format = c("category", "members"))

FairRps(ens, obs, format = c("category", "members"))

Arguments

ens

matrix with N rows representing N time instances of categorical ensemble forecasts as follows: If 'format = category' (the default), then ens[t,r] indicates the category that the r-th ensemble member predicts for time t. Note that categories must be positive integers. If 'format = members', then ens[t,k] is the number of ensemble members that predict category k at time t.

obs

vector of length N, or matrix with N rows, representing the N observed category as follows: If ‘format = category’, obs is a vector and obs[t] is the category observed at time t. If 'format = members', obs is a matrix where obs[t,k] = 1 (and zero otherwise) if category k was observed at time t

R.new

ensemble size for which the scores should be adjusted, defaults to NA (no adjustment)

format

string, 'category' (default) or 'members' (can be abbreviated). See descriptions of arguments 'ens' and 'obs' for details.

Details

'FairRps(ens, obs)' returns 'EnsRps(ens, obs, R.new=Inf)'

Value

numeric vector of length N with the ensemble-adjusted RPS values

See Also

EnsBrier, EnsQs, EnsCrps

Examples

1
2

Example output

         1983          1984          1985          1986          1987 
 5.434783e-02  7.717391e-01  1.630435e-01  3.623188e-02  6.884058e-01 
         1988          1989          1990          1991          1992 
 1.630435e-01  3.297101e-01  5.543478e-01  3.260870e-02  4.347826e-01 
         1993          1994          1995          1996          1997 
 8.586957e-01  1.086957e-02  3.985507e-02  3.804348e-01  3.297101e-01 
         1998          1999          2000          2001          2002 
 2.173913e-02  5.434783e-02  5.543478e-01  1.304348e-01  9.384058e-01 
         2003          2004          2005          2006          2007 
 1.554348e+00 -3.035766e-18  1.992754e-01  2.028986e-01  1.992754e-01 
         2008          2009 
 5.434783e-02  2.173913e-02 

SpecsVerification documentation built on March 26, 2020, 7:55 p.m.