wrapperFUN | R Documentation |
Launches the VALUE validation framework according to the arguments passed by the database.
wrapperFUN(
metric = c("obs", "pred", "measure"),
names = NULL,
season = c("annual", "DJF", "MAM", "JJA", "SON"),
member.aggregation = "none",
n.mem = NULL,
index.fun = NULL,
measure.fun = NULL,
index.args = NULL,
measure.args = NULL,
o = o,
p = p,
processes = data.frame(),
processNames = c(),
na.prop = 1
)
metric |
Character vector. |
names |
Character vector of the same length than |
season |
Character vector defining the target season(s). Default to annual + 4 standard seasons. |
member.aggregation |
Character vector of length one. What aggregation function should be applied to multiple realizations
before computing the indices?. Default to |
n.mem |
Number of members to be considered for validation. Default ( |
index.fun |
A character vector with the name of the R function that computes the index. |
measure.fun |
A character vector with the name of the R function that computes the measure. |
index.args |
A list with additional arguments passed to |
measure.args |
Same as |
o |
R object containing the observations as returned by |
p |
R object containing the predictions as returned by |
processes |
processes |
processNames |
Labels identifying the processes |
na.prop |
Maximum allowable proportion of missing data. Default to 0.9 |
The function is intended for internal use only, in order to launch the validation framework through the VALUE portal. It is not meant for extrenal users.
A 3D array with labelled dimensions station, season and metric
This function is not envisaged to be directly called by the user. It is internally called by the validation portal.
J. Bedia, D. San MartÃn, M. Tuni
## Not run:
# Load observations
obs.file <- file.path(find.package("VALUE"), "example_datasets", "VALUE_ECA_86_v2.zip")
o <- loadValueStations(obs.file, var = "tmin")
prdfile <- list.files(file.path(find.package("VALUE"), "example_datasets"),
pattern = "example_predictions_tmin_portal_exp1a_deterministic",
full.names = TRUE)
# Load predictions
p <- loadStationPredictions(o, predictions.file = prdfile)
# Example: computing correlation. Seasonal cycle removal is applied
vno <- wrapperFUN(metric = c('measure'),
names = c('measure'),
season = c('annual','DJF','MAM','JJA','SON'),
member.aggregation = 'none',
index.fun = NULL,
measure.fun = 'measure.cor.R',
index.args = NULL,
measure.args = list('method' = 'pearson','deseason' = TRUE),
o = o,
p = p)
str(vno)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.