ecm ecm

High-Volume Multi-Line Insurance Aggregation

Scénario de test & Cas d'usage

Business Context

A global insurance company is modeling aggregate losses across three distinct portfolios: Auto, Home, and Health. To ensure stability in the tail of the distribution, they require a high-volume simulation (100,000 iterations). To optimize performance during this large computation, they want to reduce sampling in the 'body' of the distribution while maintaining high accuracy in the tail.
Data Preparation

Generate a large Copula dataset (100k rows) and three distinct marginal distributions (Gamma, Pareto-like using LogNormal, and Exponential) to simulate high data volume.

Copied!
1 
2DATA casuser.cop_highvol;
3call streaminit(999);
4DO i = 1 to 100000;
5u_auto = rand('UNIFORM');
6u_home = rand('UNIFORM');
7u_health = rand('UNIFORM');
8OUTPUT;
9END;
10 
11RUN;
12 
13DATA casuser.marg_auto;
14call streaminit(888);
15DO i = 1 to 20000;
16_DRAWID_=1;
17val = rand('GAMMA', 5);
18OUTPUT;
19END;
20 
21RUN;
22 
23DATA casuser.marg_home;
24call streaminit(777);
25DO i = 1 to 20000;
26_DRAWID_=1;
27val = rand('LOGNORMAL', 8, 1.5);
28OUTPUT;
29END;
30 
31RUN;
32 
33DATA casuser.marg_health;
34call streaminit(666);
35DO i = 1 to 20000;
36_DRAWID_=1;
37val = rand('EXPONENTIAL');
38OUTPUT;
39END;
40 
41RUN;
42 

Étapes de réalisation

1
Run ECM with performance tuning: reduced body sampling fraction (0.1) and specific tail definition (start at 0.9).
Copied!
1 
2PROC CAS;
3ecm.ecm / copulaSample={name='cop_highvol'} marginals={{name='marg_auto', sampleVarName='val', idVarValue='u_auto'}, {name='marg_home', sampleVarName='val', idVarValue='u_home'}, {name='marg_health', sampleVarName='val', idVarValue='u_health'}} bodySampleFrac=0.1 tailStart=0.9 tailEDFAccuracy=0.0001 OUTPUT={outSample={name='vol_output', replace=true}} seed=54321;
4 
5RUN;
6 

Expected Result


The action completes efficiently. The output 'vol_output' contains a representative sample where the tail (top 10%) is densely sampled for accuracy, while the body (bottom 90%) is downsampled to 10% to save resources.