<?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: Genmod NB regression in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67765#M3270</link>
    <description>what is the mathematical relationship between accident as dependent variable and major and minor as explanatory variables?</description>
    <pubDate>Tue, 24 May 2011 15:23:26 GMT</pubDate>
    <dc:creator>Najmeh</dc:creator>
    <dc:date>2011-05-24T15:23:26Z</dc:date>
    <item>
      <title>Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67760#M3265</link>
      <description>I'm so new to SAS, and I need to do NB regression using Genmod procedure for my project. it's proved that there is a correlation between the data I've got. but when I apply my data, it estimates the parameter by 0.&lt;BR /&gt;
Could anybody help me? This is how I did it:&lt;BR /&gt;
"data crash;&lt;BR /&gt;
input  major minor  accident;&lt;BR /&gt;
datalines;&lt;BR /&gt;
 19331	18358	 10&lt;BR /&gt;
 17215	17051	 10&lt;BR /&gt;
 18539	17562	 9 &lt;BR /&gt;
 42890	14750        38&lt;BR /&gt;
 43187	14600        46&lt;BR /&gt;
 44136	14020	  44&lt;BR /&gt;
 60903	9819	          41&lt;BR /&gt;
 59018	10547	 49&lt;BR /&gt;
 65205	11292	  40&lt;BR /&gt;
 31969	21677	  40&lt;BR /&gt;
 31808	23356	  31&lt;BR /&gt;
 28179	19647	  45&lt;BR /&gt;
 29020      38400         78&lt;BR /&gt;
 29100       38408        64&lt;BR /&gt;
 29080      39560        54&lt;BR /&gt;
 31969	25190	  57&lt;BR /&gt;
 31808	25481	  51&lt;BR /&gt;
 28179	25092	  49&lt;BR /&gt;
 32172	34898	  56&lt;BR /&gt;
 33412	35950	  41&lt;BR /&gt;
 32068	33307	 50&lt;BR /&gt;
 30217	15094	  41&lt;BR /&gt;
 30581	16782	  31&lt;BR /&gt;
 32458	16560	 33&lt;BR /&gt;
&lt;BR /&gt;
run;&lt;BR /&gt;
proc genmod data=crash;&lt;BR /&gt;
&lt;BR /&gt;
 model accident = major minor / dist=negbin link=log;&lt;BR /&gt;
	run; "</description>
      <pubDate>Fri, 20 May 2011 00:07:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67760#M3265</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-20T00:07:07Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67761#M3266</link>
      <description>Your predictors are very large relative to the response variable. SAS is rounding the parameter estimates to 0.0000, even though they are not really 0. In a data step, add:&lt;BR /&gt;
major1=major/10000;&lt;BR /&gt;
minor1=minor/10000;&lt;BR /&gt;
&lt;BR /&gt;
Then, use major1 and minor1 in the model statement of genmod. You will get correct nonzero parameter estimates. In reporting or using the results, remember to rescale the parameters by dividing by 10000.</description>
      <pubDate>Fri, 20 May 2011 12:31:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67761#M3266</guid>
      <dc:creator>lvm</dc:creator>
      <dc:date>2011-05-20T12:31:09Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67762#M3267</link>
      <description>I've been struggling with this for awhile and now it works. I really appreciate it:)</description>
      <pubDate>Fri, 20 May 2011 14:01:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67762#M3267</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-20T14:01:34Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67763#M3268</link>
      <description>One more question. in proc genmod, is there anyway I can see the functional form of the regression model. For this example how these variables are related?&lt;BR /&gt;
Thanks</description>
      <pubDate>Tue, 24 May 2011 13:43:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67763#M3268</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-24T13:43:15Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67764#M3269</link>
      <description>You need to clarify what you mean.</description>
      <pubDate>Tue, 24 May 2011 15:03:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67764#M3269</guid>
      <dc:creator>lvm</dc:creator>
      <dc:date>2011-05-24T15:03:22Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67765#M3270</link>
      <description>what is the mathematical relationship between accident as dependent variable and major and minor as explanatory variables?</description>
      <pubDate>Tue, 24 May 2011 15:23:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67765#M3270</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-24T15:23:26Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67766#M3271</link>
      <description>This is given explicitly in the table of maximum likelihood estimates in the output. Each line is the parameter estimate for the predictor variable. Note that everything is in the scale of the link function used. You need to read the online documentation -- many examples of interpretation of the output.</description>
      <pubDate>Tue, 24 May 2011 15:44:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67766#M3271</guid>
      <dc:creator>lvm</dc:creator>
      <dc:date>2011-05-24T15:44:14Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67767#M3272</link>
      <description>I think this is what you mean:&lt;BR /&gt;
 Analysis Of Maximum Likelihood Parameter Estimates&lt;BR /&gt;
&lt;BR /&gt;
                                     Standard     Wald 95% Confidence          Wald&lt;BR /&gt;
     Parameter     DF    Estimate       Error           Limits           Chi-Square    Pr &amp;gt; ChiSq&lt;BR /&gt;
&lt;BR /&gt;
     Intercept      1      1.8966      0.3498      1.2111      2.5822         29.40        &amp;lt;.0001&lt;BR /&gt;
     major1         1      0.0271      0.0063      0.0147      0.0395         18.32        &amp;lt;.0001&lt;BR /&gt;
     minor1         1      0.0378      0.0075      0.0232      0.0524         25.79        &amp;lt;.0001&lt;BR /&gt;
     Dispersion     1      0.0610      0.0277      0.0251      0.1484&lt;BR /&gt;
&lt;BR /&gt;
NOTE: The negative binomial dispersion parameter was estimated by maximum likelihood.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
this shows the estimated parameters for each variable. my question is that what is the functional form. Is it like&lt;BR /&gt;
accident= 0.0271(major1)+0.0378(minor1)+1.8966&lt;BR /&gt;
or is there any option that shows how do they relate?&lt;BR /&gt;
thanks</description>
      <pubDate>Tue, 24 May 2011 16:01:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67767#M3272</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-24T16:01:12Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67768#M3273</link>
      <description>That's it. But note, the left hand side is log(expected number of accidents), since you use a log link function.</description>
      <pubDate>Tue, 24 May 2011 16:11:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67768#M3273</guid>
      <dc:creator>lvm</dc:creator>
      <dc:date>2011-05-24T16:11:19Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67769#M3274</link>
      <description>For generalized linear models, the inverse of the link function transforms the linear predictor eta back to produce the expected value of the response.  When you employ a log link (as you stated in your first post), the inverse of the log link is exponentiation, and the expected value of the response is given as&lt;BR /&gt;
&lt;BR /&gt;
E(Y) = exp(eta)&lt;BR /&gt;
&lt;BR /&gt;
where&lt;BR /&gt;
&lt;BR /&gt;
eta = 1.8966 + 0.0271*major1 + 0.0378*minor1</description>
      <pubDate>Tue, 24 May 2011 16:18:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67769#M3274</guid>
      <dc:creator>Dale</dc:creator>
      <dc:date>2011-05-24T16:18:18Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67770#M3275</link>
      <description>so Log link is actually  natural log or ln. is that correct?</description>
      <pubDate>Tue, 24 May 2011 18:09:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67770#M3275</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-24T18:09:46Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67771#M3276</link>
      <description>Yes.</description>
      <pubDate>Wed, 25 May 2011 16:30:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67771#M3276</guid>
      <dc:creator>Dale</dc:creator>
      <dc:date>2011-05-25T16:30:21Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67772#M3277</link>
      <description>Is there anyway in genmod procedure with NB dist that you can get a different parameter "α" beside the main parameters and overdispersion?</description>
      <pubDate>Thu, 26 May 2011 19:36:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67772#M3277</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-26T19:36:32Z</dc:date>
    </item>
    <item>
      <title>Re: Genmod NB regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67773#M3278</link>
      <description>There is also another problem, I used the following to see the fitted model graph&lt;BR /&gt;
ods graphic on;&lt;BR /&gt;
proc genmod data=crash;&lt;BR /&gt;
&lt;BR /&gt;
 model accident = major minor / dist=negbin link=log;&lt;BR /&gt;
 assess link / resample=10000&lt;BR /&gt;
              seed=603708000&lt;BR /&gt;
			   crpanel;&lt;BR /&gt;
 &lt;BR /&gt;
run;&lt;BR /&gt;
ods graphics off;&lt;BR /&gt;
but it doesn't shoe anything in panel of cumulative sum residual plot. Do I need to modify anything?&lt;BR /&gt;
Thanks.</description>
      <pubDate>Fri, 27 May 2011 20:26:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Genmod-NB-regression/m-p/67773#M3278</guid>
      <dc:creator>Najmeh</dc:creator>
      <dc:date>2011-05-27T20:26:47Z</dc:date>
    </item>
  </channel>
</rss>

