ensembleBMAnormal {ensembleBMA} | R Documentation |
Fits a Bayesian Model Averaging mixture of normals to ensemble forecasts. Allows specification of a training rule and forecasting dates.
ensembleBMAnormal(ensembleData, trainingDays, dates = NULL, control = controlBMAnormal(), exchangeable = NULL, minCRPS = FALSE)
ensembleData |
An ensembleData object including ensemble forecasts with
the corresponding verifying observations and their dates.
Missing values (indicated by NA ) are allowed.
|
trainingDays |
An integer giving the number of time steps (e.g. days) in the training period. There is no default. |
dates |
The dates for which BMA forecasting models are desired.
By default, this will be all dates in ensembleData
for which modeling is allowed given the training rule.
|
control |
A list of control values for the fitting functions. The defaults are
given by the function controlBMAnormal .
|
exchangeable |
A numeric or character vector or factor indicating groups of
ensemble members that are exchangeable (indistinguishable).
The modeling will have equal weights and parameters within each group.
The default determines exchangeability from ensembleData .
|
minCRPS |
A logical variable indicating whether or not to add a postprocessing step after the BMA fit to choose the standard deviation so as to minimize the CRPS for the training data. The default is not to do the CRPS minimization, because it can add considerable extra cost to the computation, particularly when there are many ensemble members. |
The output is for all of the dates
in ensembleData
, so there
will be missing entries denoted by NA
for dates that are too recent
to be forecast with the training rule.
The following methods are available for ensembleBMAnormal
objects:
cdf
, quantileForecast
, modelParameters
,
brierScore
, crps
, CRPS
and MAE
.
A list with the following output components:
training |
A list containing information on the training length and lag and the number of instances used for training for each modeling day. |
biasCoefs |
The fitted bias-correction coefficients for each ensemble member at each date. |
sd |
The fitted standard deviations for the mixture of normals model at each date. |
weights |
The fitted BMA weights for the normal components for each ensemble member at each date. |
A. E. Raftery, T. Gneiting, F. Balabdaoui and M. Polakowski, Using Bayesian model averaging to calibrate forecast ensembles, Monthly Weather Review 133:1155-1174, 2005.
C. Fraley, A. E. Raftery, T. Gneiting and J. M. Sloughter,
ensembleBMA
: An R
Package for Probabilistic Forecasting
using Ensembles and Bayesian Model Averaging,
Technical Report No. 516R, Department of Statistics, University of
Washington, 2009.
C. Fraley, A. E. Raftery, T. Gneiting, Using Bayesian Model Averaging to Calibrate Forecast Ensembles with Missing and Exchangeable Ensemble Members, (in preparation).
ensembleData
,
controlBMAnormal
,
fitBMAnormal
,
cdf
,
quantileForecast
,
modelParameters
,
brierScore
,
crps
,
MAE
data(ensBMAtest) ensMemNames <- c("gfs","cmcg","eta","gasp","jma","ngps","tcwb","ukmo") obs <- paste("T2","obs", sep = ".") ens <- paste("T2", ensMemNames, sep = ".") tempTestData <- ensembleData( forecasts = ensBMAtest[,ens], dates = ensBMAtest[,"vdate"], observations = ensBMAtest[,obs], station = ensBMAtest[,"station"], forecastHour = 48, initializationTime = "00") tempTestFit <- ensembleBMAnormal( tempTestData, trainingDays = 30) ## equivalent to ## tempTestFit <- ensembleBMA( tempTestData, trainingDays = 30, ## model = "normal")