Re: [R] Marginal and Discrete Effects of a Logit

From: Frank E Harrell Jr <>
Date: Tue 03 Oct 2006 - 13:58:43 GMT

Robi Ragan wrote:
> I am trying to compute the marginal effects from a logit.
> dPr(y=1)/dx_k
> and
> delta Pr(y=1|xbar)/ delta x_k
> I have searched the archives and seen the question asked, but never an
> answer given. Is this possible in either lrm or glm?
> Thanks,

Taking the derivative does yield a kind of marginal effect but not one that most people use. Marginal effects on a relative basis are traditionally computed via odds ratios (do ?summary.Design). You could also compute effects as probability differences but confidence intervals would not be automatic. I prefer to give confidence intervals for odds ratios and a graph translating odds ratios to risk differences as a (strong) function of baseline risk (such a graph is in my book Regression Modeling Strategies). -Frank

Frank E Harrell Jr   Professor and Chair           School of Medicine
                      Department of Biostatistics   Vanderbilt University

______________________________________________ mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible code.
Received on Wed Oct 04 00:01:01 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Tue 03 Oct 2006 - 14:30:07 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.