Description Usage Arguments Author(s) Examples
This function finds in a text file the value(s) of a given parameter, and replace it with new value(s).
1 | .setParam(params.lines, flag, flag.split, value)
|
params.lines |
a |
flag |
a |
flag.split |
a |
value |
a |
Maya Guéguen
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | ## Create a skeleton folder with the default name ('FATE_simulation')
if (dir.exists("FATE_simulation")) unlink("FATE_simulation", recursive = TRUE)
PRE_FATE.skeletonDirectory()
## Create a Global_parameters file
PRE_FATE.params_globalParameters(name.simulation = "FATE_simulation"
, required.no_PFG = 6
, required.no_strata = 5
, required.simul_duration = 100
, required.seeding_duration = c(10,50)
, required.seeding_timestep = 1
, required.seeding_input = 100
, required.max_abund_low = 30000
, required.max_abund_medium = 50000
, required.max_abund_high = 90000)
readLines("FATE_simulation/DATA/GLOBAL_PARAMETERS/Global_parameters_V1.txt")
## Change number of PFG
.setParam(params.lines = "FATE_simulation/DATA/GLOBAL_PARAMETERS/Global_parameters_V1.txt"
, flag = "NO_PFG"
, flag.split = " "
, value = 14)
readLines("FATE_simulation/DATA/GLOBAL_PARAMETERS/Global_parameters_V1.txt")
## ----------------------------------------------------------------------------------------- ##
## Load example data
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.