The VaR is defined as the empirical \(\alpha\) level quantile of the empirical distribution based on a return sample.
Arguments
- sample
- Numeric vector representing the sample upon which the Value at Risk is calculated. 
- alpha
- Numeric vector with entries in (0,1) specifying the levels at which the VaR is calculated. 
Examples
est_var(0:100, c(0.1, 0.2, 0.3))
#> [1] 10 20 30
