Computes the mean, standard deviation, skewness, kurtosis, Value-at-Risk (VaR) and Conditional Value-at-Risk CVaR) of a strategy.

extract_stats(simulation, level = 0.01)

Arguments

simulation

An object of the DynamicStrategies class.

level

A number with the desired probability level. The default is level = 0.01.

Value

A tibble with 2 columns and 6 rows.

Examples

utility <- simulate_strategy(strategy = "max_utility") cppi <- simulate_strategy(strategy = "cppi") extract_stats(utility)
#> # A tibble: 6 × 2 #> stat value #> <fct> <dbl> #> 1 PnL 10611. #> 2 Volatility 1506. #> 3 Skewness 0.448 #> 4 Kurtosis 3.35 #> 5 VaR 2501. #> 6 CVaR 2818.
extract_stats(cppi)
#> # A tibble: 6 × 2 #> stat value #> <fct> <dbl> #> 1 PnL 10688. #> 2 Volatility 2566. #> 3 Skewness 2.17 #> 4 Kurtosis 8.33 #> 5 VaR 818. #> 6 CVaR 819.