<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Vector Autoregression with parameter restriction in SAS Forecasting and Econometrics</title>
    <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/371938#M2456</link>
    <description>&lt;P&gt;Hi all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to run some Vector Autoregression with parameters restrictions. That is, I dont want to regress the dependent variable (Yt) on its lag&amp;nbsp;but other independent variables are still regressed on their lags. Please see attached file for a matrix illustration. I only want 1 lag&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also would like to obtain the variance-covariance matrix of the error terms. My code so far:&lt;/P&gt;&lt;PRE class="xis-codeBlock"&gt;proc varmax data=input_data;
   model Y = A B C/ P=1;
  * restrict AR(1, Y, {A B C}) = 0,
            XL(0, CPI, {FFR CP}) = 0; *not sure what this restrict option does as why do we set it to equal 0;
run;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/10039i8E3DEACAADCBEC55/image-size/original?v=1.0&amp;amp;px=-1" border="0" alt="VAR with parameter restriction.PNG" title="VAR with parameter restriction.PNG" /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/14013i628050438260A018/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="VAR with parameter restriction.PNG" title="VAR with parameter restriction.PNG" /&gt;</description>
    <pubDate>Fri, 30 Jun 2017 00:09:37 GMT</pubDate>
    <dc:creator>somebody</dc:creator>
    <dc:date>2017-06-30T00:09:37Z</dc:date>
    <item>
      <title>Vector Autoregression with parameter restriction</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/371938#M2456</link>
      <description>&lt;P&gt;Hi all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to run some Vector Autoregression with parameters restrictions. That is, I dont want to regress the dependent variable (Yt) on its lag&amp;nbsp;but other independent variables are still regressed on their lags. Please see attached file for a matrix illustration. I only want 1 lag&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also would like to obtain the variance-covariance matrix of the error terms. My code so far:&lt;/P&gt;&lt;PRE class="xis-codeBlock"&gt;proc varmax data=input_data;
   model Y = A B C/ P=1;
  * restrict AR(1, Y, {A B C}) = 0,
            XL(0, CPI, {FFR CP}) = 0; *not sure what this restrict option does as why do we set it to equal 0;
run;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/10039i8E3DEACAADCBEC55/image-size/original?v=1.0&amp;amp;px=-1" border="0" alt="VAR with parameter restriction.PNG" title="VAR with parameter restriction.PNG" /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/14013i628050438260A018/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="VAR with parameter restriction.PNG" title="VAR with parameter restriction.PNG" /&gt;</description>
      <pubDate>Fri, 30 Jun 2017 00:09:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/371938#M2456</guid>
      <dc:creator>somebody</dc:creator>
      <dc:date>2017-06-30T00:09:37Z</dc:date>
    </item>
    <item>
      <title>Re: Vector Autoregression with parameter restriction</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/372296#M2458</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Based on the description of your model, you&amp;nbsp;can obtain your desired result using the following PROC VARMAX specification:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc varmax data=input_data;
   model y a b c / p=1 print=(estimates) ;
   restrict ar(1,1,1)=0, ar(1,2,1)=0, ar(1,3,1)=0, ar(1,4,1)=0;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since you want the variables, A, B and C, to also be regressed on their lags, they must appear on the left-hand-side of the equation.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The output generated by PROC VARMAX includes a table labeled "Covariances of Innovations".&amp;nbsp; This is the variance-covariance matrix of the error terms, which you indicated that you also&amp;nbsp;needed.&amp;nbsp; If you&amp;nbsp;want to save this variance-covariance matrix&amp;nbsp;as a SAS data set, then you can use an ODS OUTPUT statement to do so.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Following, please find a modification of the above code, which illustrates the ODS OUTPUT statement and also provides a&amp;nbsp;modified version of the RESTRICT&amp;nbsp;statement.&amp;nbsp; The modified RESTRICT statement imposes the same restriction, but uses a more concise matrix expression.&amp;nbsp; A PROC PRINT step is added to print the ERROR_COV data set created from the ODS OUTPUT statement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc varmax data=input_data;
   ods output CovInnovation=error_cov;
   model y a b c / p=1 print=(estimates) ;
   restrict ar(1,{1,2,3,4},1)=0;
run;

proc print data=error_cov;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I hope this helps!&lt;/P&gt;
&lt;P&gt;DW&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jun 2017 20:02:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/372296#M2458</guid>
      <dc:creator>dw_sas</dc:creator>
      <dc:date>2017-06-30T20:02:04Z</dc:date>
    </item>
    <item>
      <title>Re: Vector Autoregression with parameter restriction</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/373467#M2481</link>
      <description>&lt;P&gt;Thanks, this works fine.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jul 2017 00:49:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Vector-Autoregression-with-parameter-restriction/m-p/373467#M2481</guid>
      <dc:creator>somebody</dc:creator>
      <dc:date>2017-07-06T00:49:33Z</dc:date>
    </item>
  </channel>
</rss>

