brierScore: Brier Score

Description Usage Arguments Details Value References See Also Examples

Description

Computes the Brier score for the probability of exceedance of precipitation threshold values for univariate ensemble forecasting models.

Usage

1
brierScore(fit, ensembleData, thresholds, dates=NULL, ...)

Arguments

fit

A model fit to ensemble forecasting data, obtained using fitMOS or
ensembleMOS. Only available for the censored and shifted gamma, and the censored generalized extreme value distribution model.

ensembleData

An ensembleData object that includes ensemble forecasts, verification observations and possibly dates. Missing values (indicated by NA) are allowed. This need not be the data used for the model fit, although it must include the same ensemble members.

thresholds

Threshold values for which the probability of exceedance is evaluated, set to 0 to evaluate probability of precipitation forecasts.

dates

The dates for which the CRPS will be computed. These dates must be consistent with fit and ensembleData. The default is to use all of the dates in fit. The dates are ignored if fit originates from fitMOS, which also ignores date information.

...

Included for generic function compatibility.

Details

Note that the Brier scores are only available for EMOS models suitable for precipitation accumulation, i.e. the censored and shifted gamma, and the censored generalized extreme value distribution EMOS model.

Value

BScores is a vector giving the Brier scores for each instance in the data.

References

T. Gneiting and A. E. Raftery, Strictly proper scoring rules, prediction and estimation, Journal of the American Statistical Association 102:359–378, 2007.

See Also

ensembleMOS, fitMOS

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
data("ensBMAtest", package = "ensembleBMA")

ensMemNames <- c("gfs","cmcg","eta","gasp","jma","ngps","tcwb","ukmo")

obs <- paste("PCP24","obs", sep = ".")
ens <- paste("PCP24", ensMemNames, sep = ".")
prcpTestData <- ensembleData(forecasts = ensBMAtest[,ens],
                             dates = ensBMAtest[,"vdate"],
                             observations = ensBMAtest[,obs],
                             station = ensBMAtest[,"station"],
                             forecastHour = 48,
                             initializationTime = "00")

prcpTestFitCSG0 <- ensembleMOScsg0(prcpTestData, trainingDays = 25,
                                   dates = "2008010100")

brierScore(prcpTestFitCSG0, ensembleData = prcpTestData, 
           thresholds = 0)

Example output

Loading required package: ensembleBMA
Loading required package: chron
Loading required package: evd

Attaching package: 'ensembleMOS'

The following objects are masked from 'package:ensembleBMA':

    brierScore, cdf, crps, quantileForecast, trainingData



modeling for date 2008010100 ...
(Intercept)   PCP24.gfs  PCP24.cmcg   PCP24.eta  PCP24.gasp   PCP24.jma 
       0.00        0.12        0.00        0.02        0.11        0.25 
 PCP24.ngps  PCP24.tcwb  PCP24.ukmo 
       0.14        0.00        0.01 
               
0.15 0.01 0.01 

Warning message:
In ensembleMOScsg0(prcpTestData, trainingDays = 25, dates = "2008010100") :
  options for chosing optimization methods are unavailable. Constrained minimization 'L-BFGS-G' is applied
            0
63 0.14560932
64 0.01751548

ensembleMOS documentation built on May 2, 2019, 11:03 a.m.