var
Provides value at risk (short: VaR) of the selected stock.
Usageโ
var [-m] [-a] [-s] [-p PERCENTILE] [-d DATA_RANGE]
Parametersโ
Name | Parameter | Description | Default | Optional | Choices |
---|---|---|---|---|---|
use_mean | -m --mean | If one should use the mean of the stocks return | False | True | None |
adjusted | -a --adjusted | If the VaR should be adjusted for skew and kurtosis (Cornish-Fisher-Expansion) | False | True | None |
student_t | -s --student | If one should use the student-t distribution | False | True | None |
percentile | -p --percentile | Percentile used for VaR calculations, for example input 99.9 equals a 99.9 Percent VaR | 99.9 | True | None |
data_range | -d --datarange | Number of rows you want to use VaR over, ex: if you are using days, 30 would show VaR for the last 30 TRADING days | 0 | True | None |
Examplesโ
2022 Feb 16, 11:18 (๐ฆ) /stocks/qa/ $ var
FB Value at Risk
โโโโโโโโโณโโโโโโโโโโณโโโโโโโโโโโโโโโโโโ
โ โ VaR: โ Historical VaR: โ
โกโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฉ
โ 90.0% โ -0.0305 โ -0.0233 โ
โโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโโโโโโค
โ 95.0% โ -0.0389 โ -0.0364 โ
โโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโโโโโโค
โ 99.0% โ -0.0546 โ -0.0578 โ
โโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโโโโโโค
โ 99.9% โ -0.0719 โ -0.1719 โ
โโโโโโโโโดโโโโโโโโโโดโโโโโโโโโโโโโโโโโโ