copula copulaViewStore

Joint Default Probability Model Review

Scénario de test & Cas d'usage

Business Context

A financial institution is modeling the dependency between two credit portfolios (Portfolio A and Portfolio B) using a t-Copula to assess systemic risk. Before deploying the model for stress testing, the risk management team needs to extract and review the correlation matrix and final parameter estimates to ensure they align with historical benchmarks.
Data Preparation

Simulation of correlated returns for two portfolios.

Copied!
1 
2DATA mycas.risk_portfolios;
3DO i = 1 to 2000;
4u1 = rand('Normal');
5u2 = u1 * 0.7 + rand('Normal') * sqrt(1 - 0.7**2);
6OUTPUT;
7END;
8 
9RUN;
10 

Étapes de réalisation

1
Fit a t-Copula model to the portfolio data and save the model context to an item store named 'riskStore'.
Copied!
1 
2PROC CAS;
3copula.copulaFit TABLE={name='risk_portfolios'} copula='T' var={'u1', 'u2'} store={name='riskStore', replace=true};
4 
5RUN;
6 
2
Use copulaViewStore to inspect specific components (Final Estimates and Correlations) and save them as CAS tables for the reporting dashboard.
Copied!
1 
2PROC CAS;
3copula.copulaViewStore / instore={name='riskStore'} viewOptions={finalEstimates=true, correlations=true} outputTables={names={'FinalEstimates', 'Correlations'}};
4 
5RUN;
6 

Expected Result


The action successfully retrieves the model from 'riskStore'. It displays and saves only the 'FinalEstimates' and 'Correlations' tables to the CAS library, allowing the risk team to validate the correlation coefficient (approx 0.7) and degrees of freedom.