% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/CST_Calibration.R
\name{CST_Calibration}
\alias{CST_Calibration}
\title{Forecast Calibration}
\usage{
CST_Calibration(exp, obs, cal.method = "bias",
  eval.method = "take-one-out", ...)
}
\arguments{
\item{exp}{an object of class \code{s2dv_cube} as returned by \code{CST_Load} function, containing the seasonal forecast experiment data in the element named \code{$data}.}

\item{obs}{an object of class \code{s2dv_cube} as returned by \code{CST_Load} function, containing the observed data in the element named \code{$data}.}

\item{cal.method}{is the calibration method used, can be either \code{"bias"}, \code{"cal"} or \code{"mbm_cal"}. Default value is \code{"bias"}.}

\item{eval.method}{is the sampling method used, can be either \code{"in-sample"} or \code{"take-one-out"}. Default value is the \code{"take-one-out"} cross validation.}

\item{...}{other parameters to be passed on to the calibration procedure}
}
\value{
an object of class \code{s2dv_cube} containing the calibrated forecasts in the element \code{$data} with the same dimensions of the experimental data.
}
\description{
Three types bias correction can be implemented. The first \code{"bias"} method simply subtracts the mean bias.

The \code{"cal"} method applies a variance inflation technique described in Doblas-Reyes et al. (2005) in leave-one-out cross-validation. This bias adjustment method produces calibrated forecasts with equivalent mean and variance to that of the reference dataset, but at the same time preserve reliability.

This \code{mbm_cal} method applies a member-by-member ensemble bias correction described in Van Schaeybroeck and Vannitsem (2015). The adjusted forecasts has an optimized CRPS score. This implies the (near) correspondence of 1) forecast mean with observational mean, 2) forecast variability with observational variability, 3) mean squared error with average ensemble variability such that the ensemble is reliable.
}
\references{
Doblas-Reyes F.J, Hagedorn R, Palmer T.N. The rationale behind the success of multi-model ensembles in seasonal forecasting-II calibration and combination. Tellus A. 2005;57:234-252. doi:10.1111/j.1600-0870.2005.00104.x

Van Schaeybroeck, B., & Vannitsem, S. (2015). Ensemble post‐processing using member‐by‐member approaches: theoretical aspects. Quarterly Journal of the Royal Meteorological Society, 141(688), 807-818.
}
\seealso{
\code{\link{CST_Load}}

# Example
# Creation of sample s2dverification objects. These are not complete
# s2dverification objects though. The Load function returns complete objects.
mod1 <- 1 : (1 * 3 * 4 * 5 * 6 * 7)
dim(mod1) <- c(dataset = 1, member = 3, sdate = 4, ftime = 5, lat = 6, lon = 7)
obs1 <- 1 : (1 * 1 * 4 * 5 * 6 * 7)
dim(obs1) <- c(dataset = 1, member = 1, sdate = 4, ftime = 5, lat = 6, lon = 7)
lon <- seq(0, 30, 5)
lat <- seq(0, 25, 5)
exp <- list(data = mod1, lat = lat, lon = lon)
obs <- list(data = obs1, lat = lat, lon = lon)
attr(exp, 'class') <- 's2dv_cube'
attr(obs, 'class') <- 's2dv_cube'
a <- CST_Calibration(exp = exp, obs = obs, cal.method = "cal", eval.method = "in-sample")
str(a)
}
\author{
Verónica Torralba, \email{veronica.torralba@bsc.es} and Bert Van Schaeybroeck, \email{bertvs@meteo.be}
}
