Description Usage Arguments Value Author(s) References See Also Examples
Provides weights on simulated scenarios from a baseline stochastic model, such that stressed random variables fulfill given probabilistic constraints (e.g. specified values for risk measures), under the new scenario weights. Scenario weights are selected by constrained minimisation of the Wasserstein Distance to the baseline model.
1 | stress_wass(type = c("RM", "mean sd", "RM mean sd", "HARA RM"), x, ...)
|
type |
Type of stress, one of |
x |
A vector, matrix or data frame
containing realisations of random variables. Columns of |
... |
Arguments to be passed on, depending on |
An object of class SWIMw
, see SWIM
for details.
Zhuomin Mao
Pesenti2019reverseSWIM
Pesenti2020SSRNSWIM
Csiszar1975SWIM
Other stress functions:
stress_HARA_RM_w()
,
stress_RM_mean_sd_w()
,
stress_RM_w()
,
stress_VaR_ES()
,
stress_VaR()
,
stress_mean_sd_w()
,
stress_mean_sd()
,
stress_mean_w()
,
stress_mean()
,
stress_moment()
,
stress_prob()
,
stress_user()
,
stress()
1 2 3 4 5 6 7 8 9 10 | ## Not run:
set.seed(0)
x <- as.data.frame(cbind(
"normal" = rnorm(1000),
"gamma" = rgamma(1000, shape = 2)))
res <- stress_wass(type = "RM", x = x,
alpha = 0.9, q_ratio = 1.05)
summary(res)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.