Python ile Nicel Risk Yönetimi
Jamsheed Shorish
Computational Economist






Örnek: 2007 - 2009 için blok maksimumları
maxima = losses.resample("W").max()
Genelleştirilmiş Aşırı Değer Dağılımı (GEV)
scipy.stats.genextreme ile parametrik tahminfrom scipy.stats import genextreme
params = genextreme.fit(maxima)
.ppf() kullanınparams gerekir.expect() kullanınVaR_99 = genextreme.ppf(0.99, *params)
CVar_99 = ( 1 / (1 - 0.99) ) * genextreme.expect(lambda x: x, *params, lb = VaR_99)
Python ile Nicel Risk Yönetimi