<?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: 2-stage Heckman procedure - parameters? in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/525529#M4987</link>
    <description>&lt;P&gt;Have you checked the implementation of this method in proc QLIM (part of SAS/ETS)?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://documentation.sas.com/?docsetId=etsug&amp;amp;docsetTarget=etsug_qlim_details17.htm&amp;amp;docsetVersion=14.3&amp;amp;locale=en" target="_self"&gt;https://documentation.sas.com/?docsetId=etsug&amp;amp;docsetTarget=etsug_qlim_details17.htm&amp;amp;docsetVersion=14.3&amp;amp;locale=en&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 08 Jan 2019 18:50:52 GMT</pubDate>
    <dc:creator>PGStats</dc:creator>
    <dc:date>2019-01-08T18:50:52Z</dc:date>
    <item>
      <title>2-stage Heckman procedure - parameters?</title>
      <link>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/525434#M4971</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am currently trying to run the two stage heckman method&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am currently rewriting a stata program into SAS and there is a do file containing this method&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I started by doing like this website to translate the stata into sas:&lt;/P&gt;&lt;P&gt;&lt;A href="https://stats.idre.ucla.edu/sas/code/heckman-selection-model/" target="_blank"&gt;https://stats.idre.ucla.edu/sas/code/heckman-selection-model/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It runs ok but later in the stata code they are calling two parameters after this procedure: lambda and sigma&lt;/P&gt;&lt;P&gt;you can learn from these parameters here:&amp;nbsp;&lt;A href="https://www.stata.com/manuals13/rheckman.pdf" target="_blank"&gt;https://www.stata.com/manuals13/rheckman.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;there are called in stata with e(lambda) and e(sigma)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The problem is the following: I have no idea how to access to these two parameters in SAS&lt;/P&gt;&lt;P&gt;I tried to find it with google without any success&lt;/P&gt;&lt;P&gt;Anyone has an idea?&lt;/P&gt;&lt;P&gt;I am currently using SAS entreprise guide 7.1&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks for your help&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Jan 2019 15:12:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/525434#M4971</guid>
      <dc:creator>henribu</dc:creator>
      <dc:date>2019-01-08T15:12:52Z</dc:date>
    </item>
    <item>
      <title>Re: 2-stage Heckman procedure - parameters?</title>
      <link>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/525529#M4987</link>
      <description>&lt;P&gt;Have you checked the implementation of this method in proc QLIM (part of SAS/ETS)?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://documentation.sas.com/?docsetId=etsug&amp;amp;docsetTarget=etsug_qlim_details17.htm&amp;amp;docsetVersion=14.3&amp;amp;locale=en" target="_self"&gt;https://documentation.sas.com/?docsetId=etsug&amp;amp;docsetTarget=etsug_qlim_details17.htm&amp;amp;docsetVersion=14.3&amp;amp;locale=en&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Jan 2019 18:50:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/525529#M4987</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2019-01-08T18:50:52Z</dc:date>
    </item>
    <item>
      <title>Re: 2-stage Heckman procedure - parameters?</title>
      <link>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/527713#M5349</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your answer&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes I checked this and they are doing exactly what I am doing&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The only thing that could be added to what I've mentioned is the heckit option&amp;nbsp;&lt;/P&gt;&lt;P&gt;But this does not tell me how to get access to the lambda and the sigma&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For instance, if I should compute another variable that is depending of the lambda of the estimation,&lt;/P&gt;&lt;P&gt;how I should access to lambda in the code?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Moreover, I tried to replicate the results obtained with stata and they differ&lt;/P&gt;&lt;P&gt;I do not understand why&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I ran the two regressions with exactly the same dataset and I obtained different results&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc qlim data=dtest;&lt;/P&gt;&lt;P&gt;model varex = var1 var2 var3/discrete;&lt;/P&gt;&lt;P&gt;model varex2 = var2 var4 var5 select(varex=1);&lt;/P&gt;&lt;P&gt;nloptions maxiter=4000000;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also tried with the heckit option&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc qlim data=dtest heckit ;&lt;/P&gt;&lt;P&gt;model varex = var1 var2 var3/discrete;&lt;/P&gt;&lt;P&gt;model varex2 = var2 var4 var5 select(varex=1);&lt;/P&gt;&lt;P&gt;nloptions maxiter=4000000;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;and I am still obtaining different results than with stata and the following code:&lt;/P&gt;&lt;P&gt;heckman&amp;nbsp; &lt;SPAN&gt;varex2 = var2 var4 var5&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&amp;nbsp;if varex == 1, select(&lt;SPAN&gt;var1 var2 var3&lt;/SPAN&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks if someone has any idea&lt;/P&gt;</description>
      <pubDate>Wed, 16 Jan 2019 14:21:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/2-stage-Heckman-procedure-parameters/m-p/527713#M5349</guid>
      <dc:creator>henribu</dc:creator>
      <dc:date>2019-01-16T14:21:19Z</dc:date>
    </item>
  </channel>
</rss>

