This function loops over one of the arguments in simulate_strategy
to make explicit the impact of a variable in the desired allocation policy.
plot_sensivities(strategy, variable, from, to, size, ...)
strategy | An object of the |
---|---|
variable | A |
from | An |
to | An |
size | A |
... | Currently not used. |
A ggplot2
object.
# stress-test the `max_utility` strategy by changing the `allocation` parameter x <- simulate_strategy() plot_sensivities(strategy = x, variable = "allocation", from = 0.0, to = 1, size = 20)# stress-test the `cppi` strategy by changing the `floor` parameter y <- simulate_strategy(strategy = "cppi") plot_sensivities(strategy = y, variable = "floor", from = 7000, to = 9000, size = 20)# stress-test on the `obpi` strategy by changing the risk-free rate y <- simulate_strategy(strategy = "obpi") plot_sensivities(strategy = y, variable = "rf", from = 0, to = 0.2, size = 20)