djbolder / credit-risk-modelling Goto Github PK
View Code? Open in Web Editor NEWCredit-Risk Modelling Libraries
License: GNU General Public License v3.0
Credit-Risk Modelling Libraries
License: GNU General Public License v3.0
File "D:\Anaconda3\lib\site-packages\rpy2\robjects\packages.py", line 471, in importr
raise PackageNotInstalledError(
PackageNotInstalledError: The R package "GIGrvg" is not installed.
Hi David,
Files exposures.npy and defaultProbabilites.npy are not functioning properly. Hope you see this and can get them updated.
Thank you
def computeRiskMeasures(M,lossDistribution,alpha):
expectedLoss = np.mean(lossDistribution)
unExpectedLoss = np.std(lossDistribution)
expectedShortfall = np.zeros([len(alpha)])
var = np.zeros([len(alpha)])
for n in range(0,len(alpha)):
expectedShortfall[n] = np.mean(lossDistribution[np.ceil(alpha[n](M-1)).astype(int):M-1])
var[n] = lossDistribution[np.ceil(alpha[n](M-1)).astype(int)]
return expectedLoss,unExpectedLoss,var,expectedShortfall
computeRiskMeasures(100,lossDistribution,0.05)
Is Alpha like 0.01 0.05 ?
If anyone could add crPlusMultifactor call to the codebase, that would be great. I'm a bit perplexed about wMat parameter usage in particular. Thank you.
Hi
Import threshold and mertonmodel modules cause dead kernel in jupyter.
I cannot get most of the exercises to run as I get dead kernel likely related to above issue.
I am using python 3.7 and have installed rpy2 and r-GIGrvg as well as all the other packages and have isntalled R in the environment. I have tried on two separate pc with anaconda and get this same problem.
Any suggestions please?
Hi Dr. Bolder, how are you? I hope doing well.
Recently, I bought the book "Credit-Risk Modelling - Theoretical Foundations, Diagnostic Tools, Practical Examples, and Numerical Recipes in Python" written by you. First of all, I'd like to say this book is awesome! Thanks so much for your contribution!.
I have tried to develop something in Python aiming to calculate the transition matrix for a specific sample considering the cohort and hazard rate approaches, and also some confidence levels using bootstrap. Unfortunately, I'm not a Python expert, and at this point I wasn't able to accomplish it in Python.
I'm sending as an attached file the output results achieved through a Visual Basic for Applications function. I've been trying to achieve the same results using the Python. I would be so grateful if you are able to send me a code developed in Python in order to achieve the same results.
Input_RatingTransitionMatrix.txt
Output_RatingTransitionMatrix.xlsx
Thanks in advance.
Best regards,
Raphael
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.