ES | R Documentation |
This function computes the expected shortfall of an univariate distribution, excluding zero-inflated.
ES(p, param, family, size = 0, Nsim = 25000)
p |
value (1 x 1) at which the expected shortfall needs to be computed; between 0 and 1; (e.g 0.01, 0.05) |
param |
parameters of the distribution; (1 x p) |
family |
distribution name; run the function distributions() for help |
size |
additional parameter for some discrete distributions; run the command distributions() for help |
Nsim |
number of simulations |
es |
expected shortfall |
family = "gaussian"
theta = c(-1.5, 1.7) ;
es = ES( 0.01, theta, family)
print('Expected shortfall : ')
print(es$es)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.