compute_es: Compute Expected Shortfall given a VaR measure

Description Usage Arguments Examples

Description

Compute ES takes a VaR function and its arguments and computes the expected shortfall by taking an average of the tail VaRs.

Usage

1
compute_es(.f, ..., conf = 0.9, n = 1000)

Arguments

.f

a VaR function to compute ES with

...

further arguments to pass

conf

level of confidence

n

number of slices to approximate tail VaR with

Examples

1
2
# Compute lognormal expected shorfall function using lognormal VaR
compute_es(var_lognormal, conf = 0.9, mu, sigma, investment, holding)

dandermotj/mmr documentation built on June 4, 2019, 9:26 p.m.