parameter_set: Set of model parameters

View source: R/class-parameter_set.R

parameter_setR Documentation

Set of model parameters

Description

Set of model parameters

Usage

parameter_set(model, param = list(), tag = NA_character_)

Arguments

model

character, a string containing a model name, e.g. "GUTS-RED-IT"

param

named list of model parameters

tag

character, an optional identifier

Value

an S4 object of type parameter_set

Slots

model

character, a string containing a model name, e.g. "GUTS-RED-IT"

tag

character, an optional identifier

param

named list of model parameters

Examples

# create a parameter set and assign it
ps <- parameter_set("GUTS-RED-IT", list(kd=0.12, hb=0.3))
GUTS_RED_IT() %>% set_param(ps)

# multiple scenarios can be modified at once
c(GUTS_RED_IT(), GUTS_RED_IT()) %>%
  set_param(ps)

# model names must match, otherwise an error will be raised
try(GUTS_RED_SD() %>% set_param(ps))

cvasi documentation built on Sept. 23, 2024, 9:08 a.m.