/* *********************************************************************** */ /* CHAPITRE05 - LES POLITIQUES MONETAIRES EUROPEENNES ET LA REGLE DE TALOR */ /* *********************************************************************** */ libname exo 'Z:\Econometrie appliquee\donnees'; ods pdf file="Z:\Econometrie appliquee\Resultats\chapitre05.pdf"; title; * ------------------------------- ; * Intitulé des différentes séries ; * ------------------------------- ; * tc_fr = taux d'intérêt à court terme de la France tc_dm = taux d'intérêt à court terme de l'Allemagne tc_nl = taux d'intérêt à court terme des Pays-Bas tc_es = taux d'intérêt à court terme de l'Espagne tc_it = taux d'intérêt à court terme de l'Italie tc_uk = taux d'intérêt à court terme du Royaume-Uni pib_fr = PIB en volume de la France pib_dm = PIB en volume de l'Allemagne pib_nl = PIB en volume des Pays-Bas pib_es = PIB en volume de l'Espagne pib_it = PIB en volume de l'Italie pib_uk = PIB en volume du Royaume-Uni cpi_fr = Indice des prix à la consommation de la France cpi_dm = Indice des prix à la consommation de l'Allemagne cpi_nl = Indice des prix à la consommation des Pays-Bas cpi_es = Indice des prix à la consommation de l'Espagne cpi_it = Indice des prix à la consommation de l'Italie cpi_uk = Indice des prix à la consommation du Royaume-Uni ; * -------------------------------------------------- ; * Problème 5.1 : Evaluation par simulation ; * -------------------------------------------------- ; * Création de la variable TRIMESTRE : 1970:1 à 1998:3 ; * --------------------------------------------------- ; data chapit5; set exo.chapit05; trimestre = intnx('QTR','01jan1970'd, _n_-1); format trimestre ddmmyy.; t=_n_; run; * Point 1 : Construction des variables d'intérêt du modèle ; * -------------------------------------------------------- ; data chapit5; set chapit5; * Question 1a : Création de la variable PIBGA_xx (glissement annuel du PIB pour le pays xx ; pibga_fr = 100 * (pib_fr - lag4(pib_fr)) / lag4(pib_fr); pibga_dm = 100 * (pib_dm - lag4(pib_dm)) / lag4(pib_dm); pibga_nl = 100 * (pib_nl - lag4(pib_nl)) / lag4(pib_nl); pibga_es = 100 * (pib_es - lag4(pib_es)) / lag4(pib_es); pibga_it = 100 * (pib_it - lag4(pib_it)) / lag4(pib_it); pibga_uk = 100 * (pib_uk - lag4(pib_uk)) / lag4(pib_uk); * Question 1b : Création de la variable CPIGA_xx (glissement annuel de l'indice des prix pour le pays xx ; cpiga_fr = 100 * (cpi_fr - lag4(cpi_fr)) / lag4(cpi_fr); cpiga_dm = 100 * (cpi_dm - lag4(cpi_dm)) / lag4(cpi_dm); cpiga_nl = 100 * (cpi_nl - lag4(cpi_nl)) / lag4(cpi_nl); cpiga_es = 100 * (cpi_es - lag4(cpi_es)) / lag4(cpi_es); cpiga_it = 100 * (cpi_it - lag4(cpi_it)) / lag4(cpi_it); cpiga_uk = 100 * (cpi_uk - lag4(cpi_uk)) / lag4(cpi_uk); * Question 1c : Ecart à l'inflation cible pour le pays xx ; ecinf_fr = cpiga_fr - 2; ecinf_dm = cpiga_dm - 2; ecinf_nl = cpiga_nl - 2; ecinf_es = cpiga_es - 2; ecinf_it = cpiga_it - 2; ecinf_uk = cpiga_uk - 2; run; * Question 1d : Application de la méthode de filtrage de Hodrick & Prescott pour les pays xx ; proc expand data=chapit5 out=chapit5; convert pib_fr = hp_fr / TRANSFORMIN=(HP_T 1600); convert pib_dm = hp_dm / TRANSFORMIN=(HP_T 1600); convert pib_nl = hp_nl / TRANSFORMIN=(HP_T 1600); convert pib_es = hp_es / TRANSFORMIN=(HP_T 1600); convert pib_it = hp_it / TRANSFORMIN=(HP_T 1600); convert pib_uk = hp_uk / TRANSFORMIN=(HP_T 1600); id trimestre; run; * Glissement annuel du PIB potentiel pour le pays xx; data chapit5; set chapit5; hpga_fr = 100 * (hp_fr - lag4(hp_fr)) / lag4(hp_fr); hpga_dm = 100 * (hp_dm - lag4(hp_dm)) / lag4(hp_dm); hpga_nl = 100 * (hp_nl - lag4(hp_nl)) / lag4(hp_nl); hpga_es = 100 * (hp_es - lag4(hp_es)) / lag4(hp_es); hpga_it = 100 * (hp_it - lag4(hp_it)) / lag4(hp_it); hpga_uk = 100 * (hp_uk - lag4(hp_uk)) / lag4(hp_uk); gap_fr = 100 * (pib_fr - hp_fr) / hp_fr; gap_dm = 100 * (pib_dm - hp_dm) / hp_dm; gap_nl = 100 * (pib_nl - hp_nl) / hp_nl; gap_es = 100 * (pib_es - hp_es) / hp_es; gap_it = 100 * (pib_it - hp_it) / hp_it; gap_uk = 100 * (pib_uk - hp_uk) / hp_uk; run; * Représentation graphique des séries suivantes : - PIB et PIB potentiel, - Croissance et croissance potentielle, - Inflation et Output GAP ; goption reset=global; title height=2 "PIB et PIB potentiel de l'Allemagne"; legend1 frame across=1 mode=protect position=(top left) offset=(3 cm, -1.5 cm); axis1 label=none order=(350 to 800 by 50) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; plot (pib_dm hp_dm)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; goption reset=global; title height=2 "Croissance et crooissance potentielle de l'Allemagne"; legend1 frame across=1 mode=protect position=(top left) offset=(3 cm, -1.5 cm); axis1 label=none order=(-4 to 16 by 4) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; plot (hpga_dm pibga_dm)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; goption reset=global; title height=2 "Inflation et Output GAP de l'Allemagne"; legend1 frame across=1 mode=protect position=(top left) offset=(12 cm, -1 cm); axis1 label=none order=(-4 to 8 by 2) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; plot (gap_dm cpiga_dm)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; * Point 2 : Calcul des séries de taux de Taylor et de taux neutre ; * --------------------------------------------------------------- ; data chapit5; set chapit5; * Taux de Taylor; ts_fr = hpga_fr + cpiga_fr + 0.5*ecinf_fr + 0.5*gap_fr; ts_dm = hpga_dm + cpiga_dm + 0.5*ecinf_dm + 0.5*gap_dm; ts_nl = hpga_nl + cpiga_nl + 0.5*ecinf_nl + 0.5*gap_nl; ts_es = hpga_es + cpiga_es + 0.5*ecinf_es + 0.5*gap_es; ts_it = hpga_it + cpiga_it + 0.5*ecinf_it + 0.5*gap_it; ts_uk = hpga_uk + cpiga_uk + 0.5*ecinf_uk + 0.5*gap_uk; * Taux neutre; tn_fr = hpga_fr + cpiga_fr; tn_dm = hpga_dm + cpiga_dm; tn_nl = hpga_nl + cpiga_nl; tn_es = hpga_es + cpiga_es; tn_it = hpga_it + cpiga_it; tn_it = hpga_it + cpiga_it; tn_uk = hpga_uk + cpiga_uk; run; goption reset=global; title1 height=2 "Taux courts, taux neutres et taux de Taylor"; title2 height=2 " de l'Allemagne "; legend1 frame across=1 mode=protect position=(top left) offset=(10 cm, -1 cm); axis1 label=none order=(0 to 15 by 2.5) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; plot (tc_dm ts_dm tn_dm)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; goption reset=global; title1 height=2 "Taux courts, taux neutres et taux de Taylor"; title2 height=2 " de la France "; legend1 frame across=1 mode=protect position=(top left) offset=(15 cm, -1 cm); axis1 label=none order=(0 to 25 by 5) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; plot (tc_fr ts_fr tn_fr)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; goption reset=global; title1 height=2 "Taux courts, taux neutres et taux de Taylor"; title2 height=2 " du Royaume-Unis "; legend1 frame across=1 mode=protect position=(top left) offset=(15 cm, -1 cm); axis1 label=none order=(0 to 40 by 5) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; plot (tc_uk ts_uk tn_uk)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; * Point 3 : Calcul de l'indicateur de précision du modèle explicatif des taux courts ; * ---------------------------------------------------------------------------------- ; * Précision de la règle de Taylor simulée avec lambda1=lambda2=0 (RMSE sur 12 trimestres); * ---------------------------------------------------------------------------------------; data chapit5; set chapit5; * Différence entre taux court et taux neutre; ecn_fr = tc_fr - tn_fr; ec2n_fr=ecn_fr**2; ecn_dm = tc_dm - tn_dm; ec2n_dm=ecn_dm**2; ecn_nl = tc_nl - tn_nl; ec2n_nl=ecn_nl**2; ecn_es = tc_es - tn_es; ec2n_es=ecn_es**2; ecn_it = tc_it - tn_it; ec2n_it=ecn_it**2; ecn_uk = tc_uk - tn_uk; ec2n_uk=ecn_uk**2; run; proc expand data=chapit5 out=chapit5 method=none; id trimestre; * France; convert ec2n_fr = ec2n_fr1 / transformout=(lead 1); convert ec2n_fr = ec2n_fr2 / transformout=(lead 2); convert ec2n_fr = ec2n_fr3 / transformout=(lead 3); convert ec2n_fr = ec2n_fr4 / transformout=(lead 4); convert ec2n_fr = ec2n_fr5 / transformout=(lead 5); convert ec2n_fr = ec2n_fr6 / transformout=(lead 6); convert ec2n_fr = ec2n_fr7 / transformout=(lead 7); convert ec2n_fr = ec2n_fr8 / transformout=(lead 8); convert ec2n_fr = ec2n_fr9 / transformout=(lead 9); convert ec2n_fr = ec2n_fr10 / transformout=(lead 10); convert ec2n_fr = ec2n_fr11 / transformout=(lead 11); convert ec2n_fr = ec2n_fr12 / transformout=(lead 12); * Allemagne; convert ec2n_dm = ec2n_dm1 / transformout=(lead 1); convert ec2n_dm = ec2n_dm2 / transformout=(lead 2); convert ec2n_dm = ec2n_dm3 / transformout=(lead 3); convert ec2n_dm = ec2n_dm4 / transformout=(lead 4); convert ec2n_dm = ec2n_dm5 / transformout=(lead 5); convert ec2n_dm = ec2n_dm6 / transformout=(lead 6); convert ec2n_dm = ec2n_dm7 / transformout=(lead 7); convert ec2n_dm = ec2n_dm8 / transformout=(lead 8); convert ec2n_dm = ec2n_dm9 / transformout=(lead 9); convert ec2n_dm = ec2n_dm10 / transformout=(lead 10); convert ec2n_dm = ec2n_dm11 / transformout=(lead 11); convert ec2n_dm = ec2n_dm12 / transformout=(lead 12); * Pays-Bas; convert ec2n_nl = ec2n_nl1 / transformout=(lead 1); convert ec2n_nl = ec2n_nl2 / transformout=(lead 2); convert ec2n_nl = ec2n_nl3 / transformout=(lead 3); convert ec2n_nl = ec2n_nl4 / transformout=(lead 4); convert ec2n_nl = ec2n_nl5 / transformout=(lead 5); convert ec2n_nl = ec2n_nl6 / transformout=(lead 6); convert ec2n_nl = ec2n_nl7 / transformout=(lead 7); convert ec2n_nl = ec2n_nl8 / transformout=(lead 8); convert ec2n_nl = ec2n_nl9 / transformout=(lead 9); convert ec2n_nl = ec2n_nl10 / transformout=(lead 10); convert ec2n_nl = ec2n_nl11 / transformout=(lead 11); convert ec2n_nl = ec2n_nl12 / transformout=(lead 12); * Espagne; convert ec2n_es = ec2n_es1 / transformout=(lead 1); convert ec2n_es = ec2n_es2 / transformout=(lead 2); convert ec2n_es = ec2n_es3 / transformout=(lead 3); convert ec2n_es = ec2n_es4 / transformout=(lead 4); convert ec2n_es = ec2n_es5 / transformout=(lead 5); convert ec2n_es = ec2n_es6 / transformout=(lead 6); convert ec2n_es = ec2n_es7 / transformout=(lead 7); convert ec2n_es = ec2n_es8 / transformout=(lead 8); convert ec2n_es = ec2n_es9 / transformout=(lead 9); convert ec2n_es = ec2n_es10 / transformout=(lead 10); convert ec2n_es = ec2n_es11 / transformout=(lead 11); convert ec2n_es = ec2n_es12 / transformout=(lead 12); * Italie; convert ec2n_it = ec2n_it1 / transformout=(lead 1); convert ec2n_it = ec2n_it2 / transformout=(lead 2); convert ec2n_it = ec2n_it3 / transformout=(lead 3); convert ec2n_it = ec2n_it4 / transformout=(lead 4); convert ec2n_it = ec2n_it5 / transformout=(lead 5); convert ec2n_it = ec2n_it6 / transformout=(lead 6); convert ec2n_it = ec2n_it7 / transformout=(lead 7); convert ec2n_it = ec2n_it8 / transformout=(lead 8); convert ec2n_it = ec2n_it9 / transformout=(lead 9); convert ec2n_it = ec2n_it10 / transformout=(lead 10); convert ec2n_it = ec2n_it11 / transformout=(lead 11); convert ec2n_it = ec2n_it12 / transformout=(lead 12); * Royaume-Uni; convert ec2n_uk = ec2n_uk1 / transformout=(lead 1); convert ec2n_uk = ec2n_uk2 / transformout=(lead 2); convert ec2n_uk = ec2n_uk3 / transformout=(lead 3); convert ec2n_uk = ec2n_uk4 / transformout=(lead 4); convert ec2n_uk = ec2n_uk5 / transformout=(lead 5); convert ec2n_uk = ec2n_uk6 / transformout=(lead 6); convert ec2n_uk = ec2n_uk7 / transformout=(lead 7); convert ec2n_uk = ec2n_uk8 / transformout=(lead 8); convert ec2n_uk = ec2n_uk9 / transformout=(lead 9); convert ec2n_uk = ec2n_uk10 / transformout=(lead 10); convert ec2n_uk = ec2n_uk11 / transformout=(lead 11); convert ec2n_uk = ec2n_uk12 / transformout=(lead 12); run; data chapit5; set chapit5; mean_ec2n_fr = mean(of ec2n_fr1--ec2n_fr12); mean_ec2n_dm = mean(of ec2n_dm1--ec2n_dm12); mean_ec2n_nl = mean(of ec2n_nl1--ec2n_nl12); mean_ec2n_it = mean(of ec2n_it1--ec2n_it12); mean_ec2n_es = mean(of ec2n_es1--ec2n_es12); mean_ec2n_uk = mean(of ec2n_uk1--ec2n_uk12); rmse_fr = lag12(sqrt(mean_ec2n_fr)); rmse_dm = lag12(sqrt(mean_ec2n_dm)); rmse_nl = lag12(sqrt(mean_ec2n_nl)); rmse_it = lag12(sqrt(mean_ec2n_it)); rmse_es = lag12(sqrt(mean_ec2n_es)); rmse_uk = lag12(sqrt(mean_ec2n_uk)); run; data chapit5; set chapit5; drop ec2n_fr1--ec2n_uk12 mean_ec2n_fr--mean_ec2n_uk; run; goption reset=global; title height=2 "Précision de la règle de Taylor simulée"; legend1 frame across=1 mode=protect position=(top left) offset=(15 cm, -1 cm); axis1 label=none order=(0 to 18 by 2) width=1 value=(h=1); axis2 label=none order=('01jan1973'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; symbol4 value=none i=join color=orange; symbol5 value=none i=join color=green; symbol6 value=none i=join color=cyan; plot (rmse_fr rmse_dm rmse_nl rmse_it rmse_es rmse_uk)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; * Précision de la règle de Taylor simulée avec lambda1=lambda2=0.5 (RMSE sur 12 trimestres); * -----------------------------------------------------------------------------------------; data chapit5; set chapit5; * Différence entre taux court et taux de Taylor; er_fr = tc_fr - ts_fr; er2_fr=er_fr**2; er_dm = tc_dm - ts_dm; er2_dm=er_dm**2; er_nl = tc_nl - ts_nl; er2_nl=er_nl**2; er_es = tc_es - ts_es; er2_es=er_es**2; er_it = tc_it - ts_it; er2_it=er_it**2; er_uk = tc_uk - ts_uk; er2_uk=er_uk**2; run; proc expand data=chapit5 out=chapit5 method=none; id trimestre; * France; convert er2_fr = er2_fr1 / transformout=(lead 1); convert er2_fr = er2_fr2 / transformout=(lead 2); convert er2_fr = er2_fr3 / transformout=(lead 3); convert er2_fr = er2_fr4 / transformout=(lead 4); convert er2_fr = er2_fr5 / transformout=(lead 5); convert er2_fr = er2_fr6 / transformout=(lead 6); convert er2_fr = er2_fr7 / transformout=(lead 7); convert er2_fr = er2_fr8 / transformout=(lead 8); convert er2_fr = er2_fr9 / transformout=(lead 9); convert er2_fr = er2_fr10 / transformout=(lead 10); convert er2_fr = er2_fr11 / transformout=(lead 11); convert er2_fr = er2_fr12 / transformout=(lead 12); * Allemagne; convert er2_dm = er2_dm1 / transformout=(lead 1); convert er2_dm = er2_dm2 / transformout=(lead 2); convert er2_dm = er2_dm3 / transformout=(lead 3); convert er2_dm = er2_dm4 / transformout=(lead 4); convert er2_dm = er2_dm5 / transformout=(lead 5); convert er2_dm = er2_dm6 / transformout=(lead 6); convert er2_dm = er2_dm7 / transformout=(lead 7); convert er2_dm = er2_dm8 / transformout=(lead 8); convert er2_dm = er2_dm9 / transformout=(lead 9); convert er2_dm = er2_dm10 / transformout=(lead 10); convert er2_dm = er2_dm11 / transformout=(lead 11); convert er2_dm = er2_dm12 / transformout=(lead 12); * Pays-Bas; convert er2_nl = er2_nl1 / transformout=(lead 1); convert er2_nl = er2_nl2 / transformout=(lead 2); convert er2_nl = er2_nl3 / transformout=(lead 3); convert er2_nl = er2_nl4 / transformout=(lead 4); convert er2_nl = er2_nl5 / transformout=(lead 5); convert er2_nl = er2_nl6 / transformout=(lead 6); convert er2_nl = er2_nl7 / transformout=(lead 7); convert er2_nl = er2_nl8 / transformout=(lead 8); convert er2_nl = er2_nl9 / transformout=(lead 9); convert er2_nl = er2_nl10 / transformout=(lead 10); convert er2_nl = er2_nl11 / transformout=(lead 11); convert er2_nl = er2_nl12 / transformout=(lead 12); * Espagne; convert er2_es = er2_es1 / transformout=(lead 1); convert er2_es = er2_es2 / transformout=(lead 2); convert er2_es = er2_es3 / transformout=(lead 3); convert er2_es = er2_es4 / transformout=(lead 4); convert er2_es = er2_es5 / transformout=(lead 5); convert er2_es = er2_es6 / transformout=(lead 6); convert er2_es = er2_es7 / transformout=(lead 7); convert er2_es = er2_es8 / transformout=(lead 8); convert er2_es = er2_es9 / transformout=(lead 9); convert er2_es = er2_es10 / transformout=(lead 10); convert er2_es = er2_es11 / transformout=(lead 11); convert er2_es = er2_es12 / transformout=(lead 12); * Italie; convert er2_it = er2_it1 / transformout=(lead 1); convert er2_it = er2_it2 / transformout=(lead 2); convert er2_it = er2_it3 / transformout=(lead 3); convert er2_it = er2_it4 / transformout=(lead 4); convert er2_it = er2_it5 / transformout=(lead 5); convert er2_it = er2_it6 / transformout=(lead 6); convert er2_it = er2_it7 / transformout=(lead 7); convert er2_it = er2_it8 / transformout=(lead 8); convert er2_it = er2_it9 / transformout=(lead 9); convert er2_it = er2_it10 / transformout=(lead 10); convert er2_it = er2_it11 / transformout=(lead 11); convert er2_it = er2_it12 / transformout=(lead 12); * Royaume-Uni; convert er2_uk = er2_uk1 / transformout=(lead 1); convert er2_uk = er2_uk2 / transformout=(lead 2); convert er2_uk = er2_uk3 / transformout=(lead 3); convert er2_uk = er2_uk4 / transformout=(lead 4); convert er2_uk = er2_uk5 / transformout=(lead 5); convert er2_uk = er2_uk6 / transformout=(lead 6); convert er2_uk = er2_uk7 / transformout=(lead 7); convert er2_uk = er2_uk8 / transformout=(lead 8); convert er2_uk = er2_uk9 / transformout=(lead 9); convert er2_uk = er2_uk10 / transformout=(lead 10); convert er2_uk = er2_uk11 / transformout=(lead 11); convert er2_uk = er2_uk12 / transformout=(lead 12); run; data chapit5; set chapit5; mean_er2_fr = mean(of er2_fr1--er2_fr12); mean_er2_dm = mean(of er2_dm1--er2_dm12); mean_er2_nl = mean(of er2_nl1--er2_nl12); mean_er2_it = mean(of er2_it1--er2_it12); mean_er2_es = mean(of er2_es1--er2_es12); mean_er2_uk = mean(of er2_uk1--er2_uk12); rmsee_fr = lag12(sqrt(mean_er2_fr)); rmsee_dm = lag12(sqrt(mean_er2_dm)); rmsee_nl = lag12(sqrt(mean_er2_nl)); rmsee_it = lag12(sqrt(mean_er2_it)); rmsee_es = lag12(sqrt(mean_er2_es)); rmsee_uk = lag12(sqrt(mean_er2_uk)); run; data chapit5; set chapit5; drop er2_fr1--er2_uk12 mean_er2_fr--mean_er2_uk; run; goption reset=global; title height=2 "Precision de la regle de Taylor simulee"; legend1 frame across=1 mode=protect position=(top left) offset=(15 cm, -1 cm); axis1 label=none order=(0 to 30 by 5) width=1 value=(h=1); axis2 label=none order=('01jan1973'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; symbol4 value=none i=join color=orange; symbol5 value=none i=join color=green; symbol6 value=none i=join color=cyan; plot (rmsee_fr rmsee_dm rmsee_nl rmsee_it rmsee_es rmsee_uk)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; * -------------------------------------------------------------------- ; * Problème 5.2 : Evaluation pas estimation et tests sur longue période ; * -------------------------------------------------------------------- ; * Point 1 : Estimation du modèle contraint pour chaque pays; * ---------------------------------------------------------; proc reg data=chapit5; model ecn_fr = ecinf_fr gap_fr; output out=chapit5 p=ecs_fr ; title "Estimation pour la France"; run; proc reg data=chapit5; model ecn_dm = ecinf_dm gap_dm; output out=chapit5 p=ecs_dm ; title "Estimation pour l'Allemagne"; run; proc reg data=chapit5; model ecn_nl = ecinf_nl gap_nl; output out=chapit5 p=ecs_nl ; title "Estimation pour les Pays-Bas"; run; proc reg data=chapit5; model ecn_it = ecinf_it gap_it; output out=chapit5 p=ecs_it ; title "Estimation pour l'Italie"; run; proc reg data=chapit5; model ecn_es = ecinf_es gap_es; output out=chapit5 p=ecs_es ; title "Estimation pour l'Espagne"; run; proc reg data=chapit5; model ecn_uk = ecinf_uk gap_uk; output out=chapit5 p=ecs_uk; title "Estimation pour le Royaume-Uni"; run; quit; data chapit5; set chapit5; te_fr = ecs_fr +tn_fr; te_dm = ecs_dm +tn_dm; te_nl = ecs_nl +tn_nl; te_it = ecs_it +tn_it; te_es = ecs_es +tn_es; te_uk = ecs_uk +tn_uk; run; goption reset=global; title1 height=2 "Taux courts, taux de taylor et taux estimés"; title2 height=2 "Allemagne"; legend1 frame across=1 mode=protect position=(top left) offset=(10 cm, -1 cm); axis1 label=none order=(0 to 15 by 2.5) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; plot (tc_dm ts_dm te_dm)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; goption reset=global; title1 height=2 "Taux courts, taux de taylor et taux estimés"; title2 height=2 "France"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(0 to 25 by 5) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; plot (tc_fr ts_fr te_fr)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; goption reset=global; title1 height=2 "Taux courts, taux de taylor et taux estimés"; title2 height=2 "France"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(0 to 40 by 5) width=1 value=(h=1); axis2 label=none order=('01jan1970'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=chapit5; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=blue; plot (tc_uk ts_uk te_uk)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 vref=0; format trimestre year2.; run; quit; * Point 4 : Test sur les paramètres lambda1 et lambda2; * ----------------------------------------------------; proc reg data=chapit5; model ecn_fr = ecinf_fr gap_fr; test1 : test ecinf_fr=0.5 ; test2 : test gap_fr=0.5; test3 : test ecinf_fr=gap_fr=0.5; title "Tests pour la France"; run; quit; proc reg data=chapit5; model ecn_dm = ecinf_dm gap_dm; test1 : test ecinf_dm=0.5 ; test2 : test gap_dm=0.5; test3 : test ecinf_dm=gap_dm=0.5; title "Tests pour l'Allemagne"; run; quit; proc reg data=chapit5; model ecn_nl = ecinf_nl gap_nl; test1 : test ecinf_nl=0.5 ; test2 : test gap_nl=0.5; test3 : test ecinf_nl=gap_nl=0.5; title "Tests pour les Pays-Bas"; run; quit; proc reg data=chapit5; model ecn_it = ecinf_it gap_it; test1 : test ecinf_it=0.5 ; test2 : test gap_it=0.5; test3 : test ecinf_it=gap_it=0.5; title "Tests pour l'Italie"; run; quit; proc reg data=chapit5; model ecn_es = ecinf_es gap_es; test1 : test ecinf_es=0.5 ; test2 : test gap_es=0.5; test3 : test ecinf_es=gap_es=0.5; title "Tests pour l'Espagne"; run; quit; proc reg data=chapit5; model ecn_uk = ecinf_uk gap_uk; test1 : test ecinf_uk=0.5 ; test2 : test gap_uk=0.5; test3 : test ecinf_uk=gap_uk=0.5; title "Tests pour le Royaume-Uni"; run; quit; * -------------------------------------- ; * Problème 5.3 : Analyse de la stabilité ; * -------------------------------------- ; * Point 1 : Estimation par sous-période; * -------------------------------------; data chapit5; set chapit5; /* if '01jan70'd <= trimestre < '01jan80'd then periode1=1; else periode1=0; if '01jan80'd <= trimestre < '01jan90'd then periode2=1; else periode2=0; if '01jan88'd <= trimestre <= '01jul98'd then periode3=1;else periode3=0; if '01jan90'd <= trimestre <= '01jul98'd then periode4=1;else periode4=0; */ if '01jan70'd <= trimestre < '01jan80'd then periode="periode1"; else if '01jan80'd <= trimestre < '01jan90'd then periode="periode2"; else if '01jan90'd <= trimestre <= '01jul98'd then periode="periode3"; if '01jan90'd <= trimestre <= '01jul98'd then periode4=1;else periode4=0; format trimestre ddmmyy8.; run; proc freq data=chapit5; table periode periode4; run; * Estimation et test sur la période 1 (1970 à 1979); * ------------------------------------------------; proc sort data=chapit5; by periode; run; proc reg data=chapit5; model ecn_fr = ecinf_fr gap_fr; by periode; test1 : test ecinf_fr=0.5 ; test2 : test gap_fr=0.5; test3 : test ecinf_fr=gap_fr=0.5; title "Tests pour la France"; run; quit; proc reg data=chapit5; model ecn_dm = ecinf_dm gap_dm; by periode; test1 : test ecinf_dm=0.5 ; test2 : test gap_dm=0.5; test3 : test ecinf_dm=gap_dm=0.5; title "Tests pour l'Allemagne"; run; quit; proc reg data=chapit5; model ecn_nl = ecinf_nl gap_nl; by periode; test1 : test ecinf_nl=0.5 ; test2 : test gap_nl=0.5; test3 : test ecinf_nl=gap_nl=0.5; title "Tests pour les Pays-Bas"; run; quit; proc reg data=chapit5; model ecn_it = ecinf_it gap_it; by periode; test1 : test ecinf_it=0.5 ; test2 : test gap_it=0.5; test3 : test ecinf_it=gap_it=0.5; title "Tests pour l'Italie"; run; quit; proc reg data=chapit5; model ecn_es = ecinf_es gap_es; by periode; test1 : test ecinf_es=0.5 ; test2 : test gap_es=0.5; test3 : test ecinf_es=gap_es=0.5; title "Tests pour l'Espagne"; run; quit; proc reg data=chapit5; model ecn_uk = ecinf_uk gap_uk; by periode; test1 : test ecinf_uk=0.5 ; test2 : test gap_uk=0.5; test3 : test ecinf_uk=gap_uk=0.5; title "Tests pour le Royaume-Uni"; run; quit; * Point 2 : Test de stabilité de CUSUM; * ------------------------------------; * La France; * ---------; proc autoreg data=chapit5; model ecn_fr = ecinf_fr gap_fr /reset; output out=res_fr recres=recur cusum=c1 cusumlb=lb cusumub=ub; run; goption reset=global; title1 height=2 "Test de stabilite des parametres"; title2 height=2 "France"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(-40 to 80 by 20) width=1 value=(h=1); axis2 label=none order=('01jan1973'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=res_fr; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=red; plot (c1 lb ub)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; * L'Allemagne; * -----------; proc autoreg data=chapit5; model ecn_dm = ecinf_dm gap_dm /reset; output out=res_dm recres=recur cusum=c1 cusumlb=lb cusumub=ub; run; goption reset=global; title1 height=2 "Test de stabilite des parametres"; title2 height=2 "Allemagne"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(-32 to 80 by 16) width=1 value=(h=1); axis2 label=none order=('01jan1973'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=res_dm; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=red; plot (c1 lb ub)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; * Les Pays-Bas; * ------------; proc autoreg data=chapit5; model ecn_nl = ecinf_nl gap_nl /reset; output out=res_nl recres=recur cusum=c1 cusumlb=lb cusumub=ub; run; goption reset=global; title1 height=2 "Test de stabilite des parametres"; title2 height=2 "Pays-Bas"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(-32 to 32 by 8) width=1 value=(h=1); axis2 label=none order=('01jul1978'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=res_nl; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=red; plot (c1 lb ub)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; * L'Espagne; * ---------; proc autoreg data=chapit5; model ecn_es = ecinf_es gap_es /reset; output out=res_es recres=recur cusum=c1 cusumlb=lb cusumub=ub; run; goption reset=global; title1 height=2 "Test de stabilite des parametres"; title2 height=2 "Espagne"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(-32 to 40 by 8) width=1 value=(h=1); axis2 label=none order=('01oct1973'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=res_es; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=red; plot (c1 lb ub)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; * L'Italie; * --------; proc autoreg data=chapit5; model ecn_it = ecinf_it gap_it /reset; output out=res_it recres=recur cusum=c1 cusumlb=lb cusumub=ub; run; goption reset=global; title1 height=2 "Test de stabilite des parametres"; title2 height=2 "Italie"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(-40 to 100 by 20) width=1 value=(h=1); axis2 label=none order=('01jul1973'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=res_it; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=red; plot (c1 lb ub)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; * Le Royaume-Uni; * --------------; proc autoreg data=chapit5; model ecn_uk = ecinf_uk gap_uk /reset; output out=res_uk recres=recur cusum=c1 cusumlb=lb cusumub=ub; run; goption reset=global; title1 height=2 "Test de stabilite des parametres"; title2 height=2 "Royaume-Uni"; legend1 frame across=1 mode=protect position=(top left) offset=(13 cm, -1 cm); axis1 label=none order=(-32 to 32 by 8) width=1 value=(h=1); axis2 label=none order=('01oct1975'd to '01jul1999'd by 365) width=1 value=(h=1); proc gplot data=res_uk; symbol1 value=none i=join color=black; symbol2 value=none i=join color=red; symbol3 value=none i=join color=red; plot (c1 lb ub)*trimestre / overlay legend=legend1 haxis=axis2 vaxis=axis1 ; format trimestre year2.; run; quit; ods pdf close;