hicopula aggregation of risk. More...
Go to the source code of this file.
hicopula aggregation of risk.
[in] | ds_in_configuration_table | Input configuration table. It provides information about risk sources to be aggregated and information about the corresponding scenarios. |
[in] | ds_in_copula_table | Input configuration table of the COPULA functions. It provides information about the copula functions to be used the aggregation. |
[in] | ds_in_marginal_table | Input configuration table of the marginal distributions. It provides information about the marginal distributions of the hierarchy leaves. |
[in] | ds_in_corr_tables | List the correlation matrices that have been loaded. These matrices need to match the matrices required by the configuration table DS_IN_COPULA_TABLE. |
[in] | working_libname | Working LIBNAME. By default, it is set to work. This option is typically used to facilitate debugging. |
[in] | in_alpha | Probability tail level to evaluate the Value-at-Risk |
[in] | in_seed | Seed |
[in] | in_ndraws | Number of simulation draws to be sample from the COPULAs. |
[in] | high_agg_level_var | Higher level of aggregation variable. |
[in] | low_agg_level_var | Lower level of aggregation variable. |
[out] | ds_out_risk_analysis_table | Output table. It contains results about the hicopula aggregation.. |
Given an input configuration table (DS_IN_CONFIGURATION_TABLE), a COPULA configuration table (DS_IN_COPULA_TABLE) and marginal distribution configuration table (ds_in_marginal_table), this macro will aggregate the risk sources defined in the configuration table (DS_IN_CONFIGURATION_TABLE) using hierarchical COPULA aggregation. Particular attention is needed when specifying the COPULA configuration table. This table may require COPULA functions which depends on correlation matrices. In order to successfully run this aggregation, the matrices need to be loaded.
Notice that the aggregation can be performed with respect to different scenarios: the configuration table (DS_IN_CONFIGURATION_TABLE) and the (DS_IN_CORRELATION_TABLE) need to contain a properly specified scenario variable (<SCENARIO_ID>).
The structure of the DS_IN_CONFIGURATION_TABLE table is as follows:
Variable | Type | Description |
---|---|---|
<SCENARIO_ID> | CHARACTER/NUMERIC | Scenario identifier variable. |
<NAME> | CHARACTER | Name of the risk source. |
<RISK_MEASURE> | CHARACTER | Type of risk measure: VaR, EC, etc.... |
<SUBDIVISION< | CHARACTER | It identifies the business subdivision. |
<RISK_SOURCE< | CHARACTER | It identifies the risk source. |
<COUPULA< | CHARACTER | It specifies the COPULA function. |
<MARGINAL< | CHARACTER | It specifiess the marginal distribution. |
<VAR< | CHARACTER | It specifies the variable on which the Risk Source Measure is measured. |
<GROUP< | CHARACTER | It identifies the group for the COPULA aggregation. |
<REFNAME< | CHARACTER | It identifies the reference name for COPULA aggregation. |
The structure of the DS_IN_COPULA_TABLE table is as follows:
Variable | Type | Description |
---|---|---|
<SCENARIO_ID; | CHARACTER | It identifies the scenario. |
<RISK_MEASURE; | CHARACTER | It identifies the type of risk measurement (VaR, EC, etc..). |
<NAME; | CHARACTER | It identifies the copula function. |
<PARAMETER; | CHARACTER | Parameter type: type, cov, corr, theta, df, .. |
<CVALUE; | CHARACTER | Character value for parameter "type". |
<NVALUE; | NUMERIC | Numeric value for parameters "args" and "parm". |
It is important to notice that when the <PARAMETER; is either "cov" or "corr", the corresponding value for <CVALUE; contains the name of the correlation matrix needed for the copula aggregation. The structure of these correlation matrix table is as follows:
Variable | Type | Description |
---|---|---|
<SCENARIO_ID; | CHARACTER | It identifies the scenario. |
<RISK_MEASURE; | CHARACTER | It identifies the type of risk measurement (VaR, EC, etc..). |
<NAME; | CHARACTER | It identifies the risk source . |
<TYPE; | CHARACTER | type of dependence matrix: corr |
<name 1; | NUMERIC | Risk for Name 1 |
<...; | NUMERIC | Risk for Name 2 |
<name k; | NUMERIC | Risk for Name 3 |
The structure of the DS_IN_MARGINAL_TABLE table is as follows:
Variable | Type | Description |
---|---|---|
<SCENARIO_ID; | CHARACTER | It identifies the scenario. |
<RISK_MEASURE; | CHARACTER | It identifies the type of risk measurement (VaR, EC, etc..). |
<NAME; | CHARACTER | It identifies the marginal distribution. |
<PARAMETER; | CHARACTER | Parameter type: type, args, parm. |
<CVALUE; | CHARACTER | Character value for parameter "type". |
<NVALUE; | NUMERIC | Numeric value for parameters "args" and "parm". |
Definition in file irmst_riskagg_hicopula.sas.