<?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 Re: Procx12 question in SAS Forecasting and Econometrics</title>
    <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408838#M2753</link>
    <description>&lt;P&gt;The data are in 4 digit year format&lt;/P&gt;&lt;P&gt;1700&lt;/P&gt;&lt;P&gt;1701&lt;/P&gt;&lt;P&gt;1702&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2004&lt;/P&gt;</description>
    <pubDate>Mon, 30 Oct 2017 18:46:04 GMT</pubDate>
    <dc:creator>Johnsewell22</dc:creator>
    <dc:date>2017-10-30T18:46:04Z</dc:date>
    <item>
      <title>Procx12 question</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408778#M2751</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to do a seasonal adjustment on a data set using procX12.&amp;nbsp; My error is as follows:&lt;/P&gt;&lt;P&gt;ERROR: Interval of date variable does not match INTERVAL=YEAR&lt;/P&gt;&lt;P&gt;The data set is an excel document that was properly imported (I know this because I have made a time series plot with the data).&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The year is a 4 digit year such as 1999.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My code is as follows:&lt;/P&gt;&lt;P&gt;data seasonlogsun;&lt;BR /&gt;set logsunspots;&lt;BR /&gt;date=year;&lt;BR /&gt;format date Year;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc x12 data=seasonlogsun date=date interval=year;&lt;BR /&gt;var logsun;&lt;BR /&gt;x11;&lt;BR /&gt;ods select d11;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Any help would be greatly appreciated.&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 16:27:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408778#M2751</guid>
      <dc:creator>Johnsewell22</dc:creator>
      <dc:date>2017-10-30T16:27:16Z</dc:date>
    </item>
    <item>
      <title>Re: Procx12 question</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408828#M2752</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;To clarify, are your date variable values before formatting are something like 01JAN1999, 01JAN2000, 01JAN2001, ... ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In other words, does the date variable contain month and day information that is consistent and the interval of that data is one year? If you have monthly data then it would need to be accumulated yearly first using proc timedata.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A sample of the data before formatting would be helpful&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 18:31:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408828#M2752</guid>
      <dc:creator>solarflare</dc:creator>
      <dc:date>2017-10-30T18:31:23Z</dc:date>
    </item>
    <item>
      <title>Re: Procx12 question</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408838#M2753</link>
      <description>&lt;P&gt;The data are in 4 digit year format&lt;/P&gt;&lt;P&gt;1700&lt;/P&gt;&lt;P&gt;1701&lt;/P&gt;&lt;P&gt;1702&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2004&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 18:46:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408838#M2753</guid>
      <dc:creator>Johnsewell22</dc:creator>
      <dc:date>2017-10-30T18:46:04Z</dc:date>
    </item>
    <item>
      <title>Re: Procx12 question</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408848#M2754</link>
      <description>&lt;P&gt;I think the problem is that your input is not in a SAS date format in which the numeric value represents the number of days since Jan 1, 1960. So each successive year is being interpreted as the next day rather than the next year.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To input the data correctly you need to use an informat.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Try using &lt;STRONG&gt;date = mdy (1,1,year);&lt;/STRONG&gt; in your data step instead of &lt;STRONG&gt;date = year;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;EDIT:&amp;nbsp;&lt;/STRONG&gt;In addition, to have the date display correctly, you will want to change your format statement to the following:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;format date year4.;&lt;/PRE&gt;</description>
      <pubDate>Mon, 30 Oct 2017 19:17:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Procx12-question/m-p/408848#M2754</guid>
      <dc:creator>solarflare</dc:creator>
      <dc:date>2017-10-30T19:17:24Z</dc:date>
    </item>
  </channel>
</rss>

