<?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: Logistic Regression Equation yielding different results in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68234#M19537</link>
    <description>Phoebe,&lt;BR /&gt;
&lt;BR /&gt;
SAS may be estimating the probabilty for the other outcome, i.e., SAS is estimating the probabilty of outcome 1, while your excel formula may be estimating the prob for outcome 0.  This would explain your opposite coefficients, as well.&lt;BR /&gt;
&lt;BR /&gt;
Mark</description>
    <pubDate>Wed, 02 Feb 2011 15:28:04 GMT</pubDate>
    <dc:creator>mfisher</dc:creator>
    <dc:date>2011-02-02T15:28:04Z</dc:date>
    <item>
      <title>Logistic Regression Equation yielding different results</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68233#M19536</link>
      <description>Hello,&lt;BR /&gt;
&lt;BR /&gt;
Using the coefficients obtained through my regression (logit), I am trying to write the equation in Excel so that I can demonstrate the effect of each variable on the probable outcome.  However, the probabilities that result do not match the probabilities of my SAS-scored individuals.&lt;BR /&gt;
&lt;BR /&gt;
In Excel, I'm doing it in two steps.  The first step is:&lt;BR /&gt;
&lt;BR /&gt;
= (intercept) + (b1 * x1) + (b2 * x2) .... (b9 * x9)&lt;BR /&gt;
&lt;BR /&gt;
Then in the neighboring cell, I take that result and use it in this equation:&lt;BR /&gt;
&lt;BR /&gt;
= 1/(1+(EXP((-1)*(result from above))))&lt;BR /&gt;
&lt;BR /&gt;
The resulting probability is not equal to what SAS generates when the dataset is scored.&lt;BR /&gt;
&lt;BR /&gt;
I'm not sure if this is related to my problem or not, but my dichotomous coefficients (levels are 0 or 1) that have negative estimates (for the 0 level) have a positive effect on probability.  When I manipulate these in my equation, I'm observing the opposite.&lt;BR /&gt;
&lt;BR /&gt;
Thank you for your advice!&lt;BR /&gt;
&lt;BR /&gt;
- Phoebe</description>
      <pubDate>Wed, 02 Feb 2011 14:22:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68233#M19536</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2011-02-02T14:22:01Z</dc:date>
    </item>
    <item>
      <title>Re: Logistic Regression Equation yielding different results</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68234#M19537</link>
      <description>Phoebe,&lt;BR /&gt;
&lt;BR /&gt;
SAS may be estimating the probabilty for the other outcome, i.e., SAS is estimating the probabilty of outcome 1, while your excel formula may be estimating the prob for outcome 0.  This would explain your opposite coefficients, as well.&lt;BR /&gt;
&lt;BR /&gt;
Mark</description>
      <pubDate>Wed, 02 Feb 2011 15:28:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68234#M19537</guid>
      <dc:creator>mfisher</dc:creator>
      <dc:date>2011-02-02T15:28:04Z</dc:date>
    </item>
    <item>
      <title>Re: Logistic Regression Equation yielding different results</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68235#M19538</link>
      <description>Thanks for the reply, Mark.&lt;BR /&gt;
&lt;BR /&gt;
Does it look to you that my Excel formula is estimating the prob for outcome 0?  I tried changing the negative estimates to positive, and this did not help. &lt;BR /&gt;
&lt;BR /&gt;
I'm pretty sure that the Excel formula is estimating outcome 1, because the resulting probability is fairly close to what SAS is estimating.  But it's still wrong.  &lt;BR /&gt;
&lt;BR /&gt;
I'm just not sure where the difference is...&lt;BR /&gt;
&lt;BR /&gt;
edit:  I should clarify that the intercept and coefficients that I'm using are the ones generated by the SAS procedure.

Message was edited by: Phoebe</description>
      <pubDate>Wed, 02 Feb 2011 15:34:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68235#M19538</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2011-02-02T15:34:18Z</dc:date>
    </item>
    <item>
      <title>Re: Logistic Regression Equation yielding different results</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68236#M19539</link>
      <description>I figured it out &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;  &lt;BR /&gt;
&lt;BR /&gt;
Thanks Mark for setting me down the right path...&lt;BR /&gt;
&lt;BR /&gt;
I needed to include the parameter option with my class variables:  param=ref ref=first&lt;BR /&gt;
&lt;BR /&gt;
Now I'm getting the same probabilities when I solve "longhand" as what SAS has output.</description>
      <pubDate>Wed, 02 Feb 2011 17:21:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Logistic-Regression-Equation-yielding-different-results/m-p/68236#M19539</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2011-02-02T17:21:26Z</dc:date>
    </item>
  </channel>
</rss>

