update_saved_calibration {adaptr}R Documentation

Update previously saved calibration result

Description

This function updates a previously saved "trial_calibration"-object created and saved by calibrate_trial() using a previous version of adaptr, including the embedded trial specification and trial results objects (internally using the update_saved_trials() function). This allows the use of calibration results, including the calibrated trial specification and the best simulations results from the calibration process, to be used without errors by this version of the package. The function should be run only once per saved simulation object and will issue a warning if the object is already up to date. And overview of the changes made according to the adaptr package version used to generate the original object is provided in Details.

Usage

update_saved_calibration(path, version = NULL, compress = TRUE)

Arguments

path

single character; the path to the saved "trial_calibration"-object containing the calibration result saved by calibrate_trial().

version

passed to saveRDS() when saving the updated object, defaults to NULL (as in saveRDS()), which means that the current default version is used.

compress

passed to saveRDS() when saving the updated object, defaults to TRUE (as in saveRDS()), see saveRDS() for other options.

Details

The following changes are made according to the version of adaptr used to generate the original "trial_calibration" object:

Value

Invisibly returns the updated "trial_calibration"-object.

See Also

run_trials().


[Package adaptr version 1.4.0 Index]