Contributor
Posts: 59

# PD Modelling for Calibration Bucketing Analysis - Bayesian Method Tries

Hello everyone,

I try to perform Calibration Bucketing test on my Performance and Recent data sets. To be able to do this, I created a model by using Interactive Grouping Node. Now, I need to perform Bucketing analysis, I mean my  Actual Default Rate should place between Predicted Default Rate’s Min and Max values. I have two data sets, one of them is Performance and the other one is Recent data set.

In my performance data set, I can provide the foregoing conditions as below;

 Predicted Min Predicted Max Predicted DR Actual DR 0.00% 1.00% 0.50% 0.70% 1.00% 3.00% 1.50% 2.00% 3.00% 5.00% 3.50% 4.00% 5.00% 7.00% 6.00% 6.50% 7.00% 9.00% 8.00% 8.50% 9.00% 10.00% 9.50% 9.70%

But In my recent data set, I cannot provide the conditions, as you can see below;

Actual DR exceeds Predicted Max values.

 Predicted Min Predicted Max Predicted DR Actual DR 0.00% 1.00% 0.50% 1.10% 1.00% 3.00% 1.50% 3.10% 3.00% 5.00% 3.50% 5.10% 5.00% 7.00% 6.00% 8.00% 7.00% 9.00% 8.00% 9.50% 9.00% 10.00% 9.50% 10.50%

Even though, Performance data set has %0.02 DR,Recent Data Set has %0.03 DR. This is the reason why I cannot provide the conditions on Recent data set by using Performance Data Set Scoring Code. Because I use Performance data set's Estimates on Recent Data, it seems that it is difficult to reach my aim.

``````/*-4.00 and 0.90 Proc Logistic Estimates of Performance Data Set*/
Data Performance2;
Set Performance;
Score=Log(Final_Score/(1-Final_Score));
Score_v2 = 1/(1+Exp(-1*(-4.00+(0.90*(Score)))));
Run;

Data Recent2;
Set Recent;
Score=Log(Final_Score/(1-Final_Score));
Score_v2 = 1/(1+Exp(-1*(-4.00+(0.90*(Score)))));
Run;``````

To Handle this problem, I would like to perform Bayesian Formula but I'm not sure that the following formulas meet my expectations. I thought that maybe someone can help me to perform Bayesian formulas or any other suggestion to reach my aim.

``````/*Bayesian Formula*/

DATA Performance3;
SET Performance2;
Bayes_Score=Score_v2*(1-0.02)*0.03/(1-Score_v2)*0.02*(1-0.03)+Score_v2*(1-0.02)*0.03;
RUN;

/*Bayesian Formula2*/

Data Performance4;
Set Performance;
Score1=Final_Score *(0.03/0.4985882003);
Score0=(Final_Score)*(0.97/0.5014117997);

Sum=Score1+Score0;
Score1=Score1/Sum;
Score0=Score2/Sum;

Run;

/*Bayesian Formula*/

DATA Recent3;
SET Recent2;
Bayes_Score=Score_v2*(1-0.02)*0.03/(1-Score_v2)*0.02*(1-0.03)+Score_v2*(1-0.02)*0.03;
RUN;

/*Bayesian Formula2*/

Data Recent4;
Set Recent;
Score1=Final_Score *(0.03/0.4985882003);
Score0=(Final_Score)*(0.97/0.5014117997);

Sum=Score1+Score0;
Score1=Score1/Sum;
Score0=Score2/Sum;

Run;``````

Can someone help me to how can I perform Bayesian formula in this process. Also, I would like to be happy, if I can get some other suggestions about this subject.

Thank you,

Discussion stats
• 0 replies
• 112 views
• 0 likes
• 1 in conversation