run_ensemble: Run an ensemble of offline land models; by default, no...

Description Usage Arguments Details Value Output Author(s)

View source: R/main.R

Description

Parameter combinations are selected by generating a quasi-random sequence and mapping it to a specified range for each parameter. Then, each parameter set is run through the offline land model in each of the Perfect, Adaptive, HybridPerfectAdaptive, HybridLinearAdaptive, and Linear variants. (I.e., if N parameter sets are selected, then 5N scenarios are run.)

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
run_ensemble(
  N = 500,
  aOutputDir = "./outputs",
  skip = 0,
  aType = "Hindcast",
  aIncludeSubsidies = FALSE,
  aDifferentiateParamByCrop = FALSE,
  aSampleType = "LatinHyperCube",
  aTotalSamplesPlanned = 500,
  logparallel = NULL
)

Arguments

N

Number of parameter sets to select

aOutputDir

Output directory

skip

Number of iterations to skip (i.e., if building on another run.)

aType

Scenario type: either "Reference" or "Hindcast"

aIncludeSubsidies

Boolean indicating subsidies should be added to profit

aDifferentiateParamByCrop

Boolean indicating whether all crops should use the same expectation parameters

aSampleType

String indicating what type of sampling, currently only "LatinHyperCube" and "Sobol" are supported

aTotalSamplesPlanned

Number of samples planned. For Latin Hypercube, we need to know the total before we start.

logparallel

Name of directory to use for parallel workers' log files. If NULL, then don't write log files.

Details

This function is strictly for running the ensemble of models. Analysis must be completed after the fact.

Value

List of ScenarioInfo objects for the ensemble members

Output

The model results are written to a series of files in the specified output directory. The list of ScenarioInfo objects is written to a file called scenario-info.rds in the output directory. This file can be loaded with a command such as scenaro_list <- readRDS('output/scenario-info.rds'). These objects contain links to the model output files.

Author(s)

KVC November 2017


JGCRI/gcamland documentation built on Oct. 6, 2020, 5:30 p.m.