Skip to contents

Update the value of the frequency in the simulated configuration according to a value defined by the user

Usage

update_frequency_with_desired_value(scenario, frequency)

Arguments

scenario

data.frame

frequency

numeric, list of max frequency to simulate

Value

scenario_updated

Examples

scenario_example <- create_scenario(
  system.file("input_1culture_2pop.xlsx", package = "ambre")
)
scenario_example_updated <- update_frequency_with_desired_value(scenario = scenario_example, 
                                                                frequency = c(2L,3L))
print(scenario_example_updated$config[[1]]$exposure)
#> # A tibble: 3 × 10
#>   name                 type    value   min   max mode  mean  sd    meanlog sdlog
#>   <chr>                <chr>   <dbl> <dbl> <dbl> <lgl> <lgl> <lgl> <lgl>   <lgl>
#> 1 number_of_repeatings value    1000  NA      NA NA    NA    NA    NA      NA   
#> 2 number_of_exposures  value       2  NA      NA NA    NA    NA    NA      NA   
#> 3 volume_perEvent      triang…    NA   0.5     3 NA    NA    NA    NA      NA   
print(scenario_example_updated$config[[2]]$exposure)
#> # A tibble: 3 × 10
#>   name                 type    value   min   max mode  mean  sd    meanlog sdlog
#>   <chr>                <chr>   <dbl> <dbl> <dbl> <lgl> <lgl> <lgl> <lgl>   <lgl>
#> 1 number_of_repeatings value    1000  NA      NA NA    NA    NA    NA      NA   
#> 2 number_of_exposures  value       3  NA      NA NA    NA    NA    NA      NA   
#> 3 volume_perEvent      triang…    NA   0.5     3 NA    NA    NA    NA      NA