<?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 Calculating clustered standard errors with a large number of clusters in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Calculating-clustered-standard-errors-with-a-large-number-of/m-p/451359#M23584</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am running a pretty large data set for 500,000 individuals on a daily level over 13 years. I have approximately 500 million observations.&lt;/P&gt;&lt;P&gt;I have a problem constructing clustered standard errors on the individual level.&lt;/P&gt;&lt;P&gt;It seems like I have a server size problem. I have access to 2 TB, which allows me to construct clustered standard errors for up to 60,000 individuals.&lt;/P&gt;&lt;P&gt;It seems like proc surveyreg can run with fewer clusters than proc genmod.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do anyone have an idea to how to overcome this or what to try?&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Frederik&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I get this error message with proc surveyreg:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;ERROR: The SAS System stopped processing this step because of insufficient&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;memory.&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;NOTE: PROCEDURE SURVEYREG used (Total process time):&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;real time 4:34:52.34&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;cpu time 4:34:23.42&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;This is my code, if I run with proc surveyreg:&amp;nbsp;&lt;/STRONG&gt;Attached.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 16 Apr 2018 03:30:40 GMT</pubDate>
    <dc:creator>FrederikPL</dc:creator>
    <dc:date>2018-04-16T03:30:40Z</dc:date>
    <item>
      <title>Calculating clustered standard errors with a large number of clusters</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Calculating-clustered-standard-errors-with-a-large-number-of/m-p/451359#M23584</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am running a pretty large data set for 500,000 individuals on a daily level over 13 years. I have approximately 500 million observations.&lt;/P&gt;&lt;P&gt;I have a problem constructing clustered standard errors on the individual level.&lt;/P&gt;&lt;P&gt;It seems like I have a server size problem. I have access to 2 TB, which allows me to construct clustered standard errors for up to 60,000 individuals.&lt;/P&gt;&lt;P&gt;It seems like proc surveyreg can run with fewer clusters than proc genmod.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do anyone have an idea to how to overcome this or what to try?&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Frederik&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I get this error message with proc surveyreg:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;ERROR: The SAS System stopped processing this step because of insufficient&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;memory.&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;NOTE: PROCEDURE SURVEYREG used (Total process time):&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;real time 4:34:52.34&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;cpu time 4:34:23.42&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;This is my code, if I run with proc surveyreg:&amp;nbsp;&lt;/STRONG&gt;Attached.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Apr 2018 03:30:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Calculating-clustered-standard-errors-with-a-large-number-of/m-p/451359#M23584</guid>
      <dc:creator>FrederikPL</dc:creator>
      <dc:date>2018-04-16T03:30:40Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating clustered standard errors with a large number of clusters</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Calculating-clustered-standard-errors-with-a-large-number-of/m-p/451587#M23588</link>
      <description>&lt;P&gt;It never hurts to show the code you are using. That way we can avoid making suggestions that look like what you are doing.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What exactly is the problem? No output, incorrect (or at least unexpected output), missing errors for some records?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;From the surveyreg documentation&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;Let&lt;/P&gt;
&lt;DIV&gt;
&lt;UL type="disc"&gt;
&lt;LI&gt;
&lt;P&gt;&lt;SPAN class=" AAmathtext"&gt;H&lt;/SPAN&gt; be the total number of strata&lt;/P&gt;
&lt;/LI&gt;
&lt;LI&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;IMG width="12" height="9" class="math" style="vertical-align: -2px;" alt="$n_ c$" src="http://127.0.0.1:65489/help/statug.hlp/images/statug_surveyreg0111.png" border="0" /&gt;&lt;/SPAN&gt; be the total number of clusters in your sample across all &lt;SPAN class=" AAmathtext"&gt;H&lt;/SPAN&gt; strata, if you specify a &lt;A href="http://127.0.0.1:65489/help/statug.hlp/statug_surveyreg_syntax04.htm" target="_blank"&gt;CLUSTER&lt;/A&gt; statement&lt;/P&gt;
&lt;/LI&gt;
&lt;LI&gt;
&lt;P&gt;&lt;SPAN class=" AAmathtext"&gt;p&lt;/SPAN&gt; be the total number of parameters in the model&lt;/P&gt;
&lt;/LI&gt;
&lt;/UL&gt;
&lt;/DIV&gt;
&lt;P&gt;The memory needed (in bytes) is&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV class="AAmathobject"&gt;&lt;IMG width="158" height="16" class="math" alt="\[ 48H+8pH+4p(p+1)H \]" src="http://127.0.0.1:65489/help/statug.hlp/images/statug_surveyreg0112.png" border="0" /&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;For a cluster sample, the additional memory needed (in bytes) is&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV class="AAmathobject"&gt;&lt;IMG width="289" height="16" class="math" alt="\[ 48H+8pH+4p(p+1)H+ 4p(p+1)n_ c + 16n_ c \]" src="http://127.0.0.1:65489/help/statug.hlp/images/statug_surveyreg0113.png" border="0" /&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;The SURVEYREG procedure also uses other small amounts of additional memory. However, when you have a large number of clusters or strata, or a large number of parameters in your model, the memory described previously dominates the total memory required by the procedure.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;So using the above information does the memory requirement come close to being within your available.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also there is the consideration of the output. ODS Select or Exclude might reduce some of the output table overhead.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Apr 2018 15:45:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Calculating-clustered-standard-errors-with-a-large-number-of/m-p/451587#M23588</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-04-05T15:45:26Z</dc:date>
    </item>
  </channel>
</rss>

