<?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 Help  with SAS code in SAS Forecasting and Econometrics</title>
    <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Help-with-SAS-code/m-p/108559#M583</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can someone please help me with the following coding?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to create a data set of 1000 values for the following model:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; X(t) = &lt;SPAN style="font-family: 'courier new', courier;"&gt;(1/((1-x)**0.4))&lt;/SPAN&gt;e&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,where e is a standard normal random variable and &lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;L is the lag operator&lt;/STRONG&gt;&lt;/SPAN&gt;. I don't know how to deal with the lag operator. finally I need to plot X vs. t.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I&amp;nbsp; need use the &lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;1st 100 terms of the INFINITE&amp;nbsp; BINOMIAL&lt;/STRONG&gt;&lt;/SPAN&gt; expansion of the term &lt;SPAN style="font-family: 'courier new', courier;"&gt;(1/((1-x)**0.4)).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Oct 2012 22:11:37 GMT</pubDate>
    <dc:creator>malakaext</dc:creator>
    <dc:date>2012-10-26T22:11:37Z</dc:date>
    <item>
      <title>Help  with SAS code</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Help-with-SAS-code/m-p/108559#M583</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can someone please help me with the following coding?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to create a data set of 1000 values for the following model:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; X(t) = &lt;SPAN style="font-family: 'courier new', courier;"&gt;(1/((1-x)**0.4))&lt;/SPAN&gt;e&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,where e is a standard normal random variable and &lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;L is the lag operator&lt;/STRONG&gt;&lt;/SPAN&gt;. I don't know how to deal with the lag operator. finally I need to plot X vs. t.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I&amp;nbsp; need use the &lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;1st 100 terms of the INFINITE&amp;nbsp; BINOMIAL&lt;/STRONG&gt;&lt;/SPAN&gt; expansion of the term &lt;SPAN style="font-family: 'courier new', courier;"&gt;(1/((1-x)**0.4)).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Oct 2012 22:11:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Help-with-SAS-code/m-p/108559#M583</guid>
      <dc:creator>malakaext</dc:creator>
      <dc:date>2012-10-26T22:11:37Z</dc:date>
    </item>
    <item>
      <title>Re: Help  with SAS code</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Help-with-SAS-code/m-p/108560#M584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear malakaext,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since I can't observe the lag operator in your expression, I'll try to explain you the usage of lag function in general.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;x = lagN(varname); - this will produce the value of 'varname' on a step t - N.&lt;/P&gt;&lt;P&gt;So y =&amp;nbsp; x(t-1) will be&lt;/P&gt;&lt;P&gt;y = lag1(x);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;y = x(t-3) will be&lt;/P&gt;&lt;P&gt;y = lag3(x);&lt;/P&gt;&lt;P&gt;etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Notice:&lt;/STRONG&gt; consider reading help about lag function and using it in conditional statements.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The example:&lt;/P&gt;&lt;P&gt;X(t) = (1/((1-X(t-1))**0.4))* e;&lt;/P&gt;&lt;P&gt;data Xmodel;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var t X e;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; do t = 1 to 1000;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; e = rand('NORMAL', 0, 1);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; X =&lt;SPAN style="font-family: 'courier new', courier; background-color: #ffffff;"&gt;( 1/( (1 - coalesce(lag1(X),0))**0.4 ) ) * e&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt; &lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; output;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Oct 2012 12:56:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Help-with-SAS-code/m-p/108560#M584</guid>
      <dc:creator>ghastly_kitten</dc:creator>
      <dc:date>2012-10-29T12:56:41Z</dc:date>
    </item>
  </channel>
</rss>

