powered by
This function should be used to change the filesystem paths stored in a scenario object. Useful when moving a scenario from one computer to another.
scenario_update_paths(scenario, from, to, fixed = TRUE)scenario.update.paths(scenario, from, to, fixed = TRUE)
scenario.update.paths(scenario, from, to, fixed = TRUE)
The updated scenario
(list()) Data structure containing irace settings. The data structure has to be the one returned by the function defaultScenario() or readScenario().
list()
defaultScenario()
readScenario()
character string containing a regular expression (or character string for fixed = TRUE) to be matched.
fixed = TRUE
the replacement string.character string. For fixed = FALSE this can include backreferences "\1" to "\9" to parenthesized subexpressions of from.
fixed = FALSE
"\1"
"\9"
from
logical. If TRUE, from is a string to be matched as is.
TRUE
base::grep()
if (FALSE) { scenario <- readScenario(filename = "scenario.txt") scenario <- scenario_update_paths(scenario, from = "/home/manuel/", to = "/home/leslie") }
Run the code above in your browser using DataLab