<?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 Are the standard errors from PROC SURVEYREG White SE? in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Are-the-standard-errors-from-PROC-SURVEYREG-White-SE/m-p/747586#M36380</link>
    <description>&lt;P&gt;I am trying to compute White standard errors (SE) following this post&amp;nbsp;&lt;A href="http://pages.stern.nyu.edu/~adesouza/comp/sas.html" target="_blank"&gt;http://pages.stern.nyu.edu/~adesouza/comp/sas.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;What I notice is that PROC SURVEYREG provide the same SE as the other options. So is it true that PROC SURVEYREG produces White SE as default? or am I missing anything here? I also test on other datasets and got the same results. Here are the sample dataset and code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*Get the dataset;
	filename foo1 URL "http://www.kellogg.northwestern.edu/faculty/petersen/htm/papers/se/test_data.txt";
	data ds;
	  infile foo1;
	  input firmid year x y;
	run;
*Now run different methods;
	*Normal SE;
		proc reg data=ds;
		    model y = x;
			ods output ParameterEstimates=temp0 fitstatistics=fit0;
		run;
	*option1: Using PROC SURVEYREG with no special specs;
		proc surveyreg data=ds;
			model y = x / solution;
			ods output ParameterEstimates=temp1 fitstatistics=fit1;
		run;quit;

	*option2;
		proc reg data=ds ;
			model y = x / white;
			ods output ParameterEstimates=temp2 fitstatistics=fit2;
		run;quit;
	*option3;
		proc model data=ds;
		   instruments x ;
		   y=b0+b1*misp + b2*iv + b3*mom6;
			*y = b0 + b1* x;
		   fit y / gmm kernel=(bart,1,0);
		   ods output ParameterEstimates=temp3 fitstatistics=fit3;
		run;quit;
	*option4: same as option 1 but cluster each obs. Dont know why but the article suggests so;
		data ds;
		   set ds;
		   counter=_n_;
		run;
		proc surveyreg data=ds;
		   cluster counter;
		   model y=x;
		   ods output ParameterEstimates=temp4 fitstatistics=fit4;
		run;quit;
	*option5: note that the ods output statement does not work. check the output on Results Viewer;
		proc genmod data=ds;
		   class counter;
		   model y=x;
		   repeated subject=counter /type=ind;
			ods output ParameterEstimates=temp5 fitstatistics=fit5;
		run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 13 Jun 2021 03:23:59 GMT</pubDate>
    <dc:creator>somebody</dc:creator>
    <dc:date>2021-06-13T03:23:59Z</dc:date>
    <item>
      <title>Are the standard errors from PROC SURVEYREG White SE?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Are-the-standard-errors-from-PROC-SURVEYREG-White-SE/m-p/747586#M36380</link>
      <description>&lt;P&gt;I am trying to compute White standard errors (SE) following this post&amp;nbsp;&lt;A href="http://pages.stern.nyu.edu/~adesouza/comp/sas.html" target="_blank"&gt;http://pages.stern.nyu.edu/~adesouza/comp/sas.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;What I notice is that PROC SURVEYREG provide the same SE as the other options. So is it true that PROC SURVEYREG produces White SE as default? or am I missing anything here? I also test on other datasets and got the same results. Here are the sample dataset and code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*Get the dataset;
	filename foo1 URL "http://www.kellogg.northwestern.edu/faculty/petersen/htm/papers/se/test_data.txt";
	data ds;
	  infile foo1;
	  input firmid year x y;
	run;
*Now run different methods;
	*Normal SE;
		proc reg data=ds;
		    model y = x;
			ods output ParameterEstimates=temp0 fitstatistics=fit0;
		run;
	*option1: Using PROC SURVEYREG with no special specs;
		proc surveyreg data=ds;
			model y = x / solution;
			ods output ParameterEstimates=temp1 fitstatistics=fit1;
		run;quit;

	*option2;
		proc reg data=ds ;
			model y = x / white;
			ods output ParameterEstimates=temp2 fitstatistics=fit2;
		run;quit;
	*option3;
		proc model data=ds;
		   instruments x ;
		   y=b0+b1*misp + b2*iv + b3*mom6;
			*y = b0 + b1* x;
		   fit y / gmm kernel=(bart,1,0);
		   ods output ParameterEstimates=temp3 fitstatistics=fit3;
		run;quit;
	*option4: same as option 1 but cluster each obs. Dont know why but the article suggests so;
		data ds;
		   set ds;
		   counter=_n_;
		run;
		proc surveyreg data=ds;
		   cluster counter;
		   model y=x;
		   ods output ParameterEstimates=temp4 fitstatistics=fit4;
		run;quit;
	*option5: note that the ods output statement does not work. check the output on Results Viewer;
		proc genmod data=ds;
		   class counter;
		   model y=x;
		   repeated subject=counter /type=ind;
			ods output ParameterEstimates=temp5 fitstatistics=fit5;
		run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 13 Jun 2021 03:23:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Are-the-standard-errors-from-PROC-SURVEYREG-White-SE/m-p/747586#M36380</guid>
      <dc:creator>somebody</dc:creator>
      <dc:date>2021-06-13T03:23:59Z</dc:date>
    </item>
    <item>
      <title>Re: Are the standard errors from PROC SURVEYREG White SE?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Are-the-standard-errors-from-PROC-SURVEYREG-White-SE/m-p/747855#M36390</link>
      <description>&lt;P&gt;PROC SURVEYREG uses the &lt;A href="https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/statug/statug_surveyreg_details15.htm" target="_blank" rel="noopener"&gt;Taylor series linearization method&lt;/A&gt; to compute the variance.&amp;nbsp;This robust variance estimation method is also referred to as the Huber-White sandwich estimator, the design-based estimator and the Rogers estimator.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Jun 2021 16:01:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Are-the-standard-errors-from-PROC-SURVEYREG-White-SE/m-p/747855#M36390</guid>
      <dc:creator>Zard</dc:creator>
      <dc:date>2021-06-14T16:01:47Z</dc:date>
    </item>
  </channel>
</rss>

