Rookie here, I am trying to replicate the study in the following paper:
http://support.sas.com/resources/papers/proceedings16/SAS6364-2016.pdf
The process I followed is:
-Run Proc Varmax to model BVAR on log-ratio of (RealGDP, CPI and Unemployment Rate). Save residuals in a separate dataset.
-Call Proc Copula to find he joint distribution from the marginal distribution of the residuals.
-Once I get that, I use the simulated errors with the forecast means from Varmax to create macroeconomic scenarios.
I have the following issue. My residuals do not follow normal dist. I am not sure how to transform them. Proc Copula does not seem to work with the assumptions. Any idea how I can fix this? Your help is much appreciated
I am using the following code.
PROC COPULA DATA = error_dist;
VAR Res_RGDP Res_UMP Res_CPI;
FIT Normal /
MARGINALS = uniform METHOD = MLE;
SIMULATE /
NDRAWS = 1000 SEED = 1
MARGINALS = UNIFORM
OUTUNIFORM = simulated_errors;
RUN;
The Error_Dist has values like these:
Res_RGDP Res_UMP Res_CPI
0.0398668592 0.0262994594 0.010727359
-0.029316863 0.1554613968 0.0061404736
-0.050879246 0.0763711127 -0.00331784
0.0068502877 0.1468297946 0.0019326859
0.0650468136 -0.018832064 0.0044021124
-0.008798372 0.1423033571 0.0029771118
I don't fully understand your example, but I question whether you want to be using MARGINALS=UNIFORM. Try using MARGINALS=EMPIRICAL as the option to the SIMULATE statement. That will use the empirical CDF as the basis for the simulation of the copula.
I don't fully understand your example, but I question whether you want to be using MARGINALS=UNIFORM. Try using MARGINALS=EMPIRICAL as the option to the SIMULATE statement. That will use the empirical CDF as the basis for the simulation of the copula.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.
Find more tutorials on the SAS Users YouTube channel.