
clc; clear;

addpath('ADD_PATH_HERE\Workfiles');
addpath('ADD_PATH_HERE\Scripts');


%figure


table_gdp = nan(11,4);
table_inf = nan(11,4);


%% pre-IT sample

clearvars -except table*
load 82_13_preIT_sample

table_gdp(1,1) = (VAR_FINAL.ly.jump_0(1));
table_gdp(5,1) = (VAR_FINAL.ly.jump_0(2));
table_gdp(9,1) = (VAR_FINAL.ly.jump_0(5));

table_gdp(1,2) = (VAR_FORECAST.Staff.ly.jump_0(1));
table_gdp(5,2) = (VAR_FORECAST.Staff.ly.jump_0(2));
table_gdp(9,2) = (VAR_FORECAST.Staff.ly.jump_0(5));

table_gdp(1,3) = (MSE_DATA.Staff.ly.jump_0(1));
table_gdp(5,3) = (MSE_DATA.Staff.ly.jump_0(2));
table_gdp(9,3) = (MSE_DATA.Staff.ly.jump_0(5));

table_gdp(1,4) = COV_FORECAST_ERRORS.Staff.ly.jump_0(1);
table_gdp(5,4) = COV_FORECAST_ERRORS.Staff.ly.jump_0(2);
table_gdp(9,4) = COV_FORECAST_ERRORS.Staff.ly.jump_0(5);


table_inf(1,1) = (VAR_FINAL.lpcpi.jump_0(1));
table_inf(5,1) = (VAR_FINAL.lpcpi.jump_0(2));
table_inf(9,1) = (VAR_FINAL.lpcpi.jump_0(5));

table_inf(1,2) = (VAR_FORECAST.Staff.lpcpi.jump_0(1));
table_inf(5,2) = (VAR_FORECAST.Staff.lpcpi.jump_0(2));
table_inf(9,2) = (VAR_FORECAST.Staff.lpcpi.jump_0(5));

table_inf(1,3) = (MSE_DATA.Staff.lpcpi.jump_0(1));
table_inf(5,3) = (MSE_DATA.Staff.lpcpi.jump_0(2));
table_inf(9,3) = (MSE_DATA.Staff.lpcpi.jump_0(5));

table_inf(1,4) = COV_FORECAST_ERRORS.Staff.lpcpi.jump_0(1);
table_inf(5,4) = COV_FORECAST_ERRORS.Staff.lpcpi.jump_0(2);
table_inf(9,4) = COV_FORECAST_ERRORS.Staff.lpcpi.jump_0(5);



%% IT sample

clearvars -except table*
load 82_13_IT_sample

table_gdp(2,1)  = (VAR_FINAL.ly.jump_0(1));
table_gdp(6,1)  = (VAR_FINAL.ly.jump_0(2));
table_gdp(10,1) = (VAR_FINAL.ly.jump_0(5));

table_gdp(2,2) = (VAR_FORECAST.Staff.ly.jump_0(1));
table_gdp(6,2) = (VAR_FORECAST.Staff.ly.jump_0(2));
table_gdp(10,2) = (VAR_FORECAST.Staff.ly.jump_0(5));

table_gdp(2,3) = (MSE_DATA.Staff.ly.jump_0(1));
table_gdp(6,3) = (MSE_DATA.Staff.ly.jump_0(2));
table_gdp(10,3) = (MSE_DATA.Staff.ly.jump_0(5));

table_gdp(2,4) = COV_FORECAST_ERRORS.Staff.ly.jump_0(1);
table_gdp(6,4) = COV_FORECAST_ERRORS.Staff.ly.jump_0(2);
table_gdp(10,4) = COV_FORECAST_ERRORS.Staff.ly.jump_0(5);


table_inf(2,1)  = (VAR_FINAL.lpcpi.jump_0(1));
table_inf(6,1)  = (VAR_FINAL.lpcpi.jump_0(2));
table_inf(10,1) = (VAR_FINAL.lpcpi.jump_0(5));

table_inf(2,2) = (VAR_FORECAST.Staff.lpcpi.jump_0(1));
table_inf(6,2) = (VAR_FORECAST.Staff.lpcpi.jump_0(2));
table_inf(10,2) = (VAR_FORECAST.Staff.lpcpi.jump_0(5));

table_inf(2,3) = (MSE_DATA.Staff.lpcpi.jump_0(1));
table_inf(6,3) = (MSE_DATA.Staff.lpcpi.jump_0(2));
table_inf(10,3) = (MSE_DATA.Staff.lpcpi.jump_0(5));

table_inf(2,4) = COV_FORECAST_ERRORS.Staff.lpcpi.jump_0(1);
table_inf(6,4) = COV_FORECAST_ERRORS.Staff.lpcpi.jump_0(2);
table_inf(10,4) = COV_FORECAST_ERRORS.Staff.lpcpi.jump_0(5);


%% Sample comparison

table_gdp(3,1)  = (table_gdp(2,1)-table_gdp(1,1));
table_gdp(7,1)  = (table_gdp(6,1)-table_gdp(5,1));
table_gdp(11,1) = (table_gdp(10,1)-table_gdp(9,1));

table_gdp(3,2)  = (table_gdp(2,2)-table_gdp(1,2));
table_gdp(7,2)  = (table_gdp(6,2)-table_gdp(5,2));
table_gdp(11,2) = (table_gdp(10,2)-table_gdp(9,2));

table_gdp(3,3)  = (table_gdp(2,3)-table_gdp(1,3));
table_gdp(7,3)  = (table_gdp(6,3)-table_gdp(5,3));
table_gdp(11,3) = (table_gdp(10,3)-table_gdp(9,3));

table_gdp(3,4)  = (table_gdp(2,4)-table_gdp(1,4));
table_gdp(7,4)  = (table_gdp(6,4)-table_gdp(5,4));
table_gdp(11,4) = (table_gdp(10,4)-table_gdp(9,4));


table_inf(3,1)  = (table_inf(2,1)-table_inf(1,1));
table_inf(7,1)  = (table_inf(6,1)-table_inf(5,1));
table_inf(11,1) = (table_inf(10,1)-table_inf(9,1));

table_inf(3,2)  = (table_inf(2,2)-table_inf(1,2));
table_inf(7,2)  = (table_inf(6,2)-table_inf(5,2));
table_inf(11,2) = (table_inf(10,2)-table_inf(9,2));

table_inf(3,3)  = (table_inf(2,3)-table_inf(1,3));
table_inf(7,3)  = (table_inf(6,3)-table_inf(5,3));
table_inf(11,3) = (table_inf(10,3)-table_inf(9,3));

table_inf(3,4)  = (table_inf(2,4)-table_inf(1,4));
table_inf(7,4)  = (table_inf(6,4)-table_inf(5,4));
table_inf(11,4) = (table_inf(10,4)-table_inf(9,4));


table = [table_gdp;nan(1,4);table_inf];

num2str(table,'  %.2f')

