Skip to contents

Updates a specific entry in a nested calibration parameter list for a given model.

Usage

set_cal_par(model, setting_name_value, cal_par)

Arguments

model

A string specifying the model name (e.g., "TUW"), used to access the corresponding sublist in cal_par. For a complete list see table in vignette("model_overview").

setting_name_value

A string representing the setting to update, in the format "sublist$parameter = value". This string is parsed and evaluated to modify the calibration settings.

cal_par

A list containing calibration settings for one or more models.

Value

The updated calibration settings list.

Details

This function uses non-standard evaluation to dynamically update a nested element in the cal_par list. It is useful for programmatically modifying calibration settings without manually navigating the list structure.

Examples

cal_par_updated <- set_cal_par("TUW", "DEoptim$itermax = 5", cal_par)