Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Odds ratio graph


From   Maarten Buis <[email protected]>
To   [email protected]
Subject   st: Odds ratio graph
Date   Thu, 15 Dec 2011 10:56:45 +0100

--- Adriana Dornelles wrote me privately:
> I really appreciate the code that you made available about the Odds Ratio Graph.
 <http://www.stata.com/statalist/archive/2010-09/msg00525.html>
> However, I want to graph showing only a few odds ratios , but I figured that even
> after dropping some "axis" observations, they are still showing on the graph,
> since they belong to the logit regression.
> I also tried to edit it from the graph editor, going to axis proprieties, axis rule,
> edit or add individuals ticks and tables, but because they have a (+) signal it
> does not allow you to drop this ticks (labels).
> Do you have any suggestion?
>
> In your graph you have south, married, never_married, collgrad. What if I would
> like to graph only south, married and collgrad?

Follow up questions need to be sent to the statalist and not to
individual members. This is exaplained in the Statalist FAQ:
<http://www.stata.com/support/faqs/res/statalist.html#private>

You need to drop the observations representing the variables you want
to exclude before you call -egen axis = axis(estimate), label(parm)-:

*-------------- begin example -----------------
sysuse nlsw88, clear
logit union married never_married collgrad south
parmest, norestore eform
keep if inlist(parm, "south", "married", "collgrad")
egen axis= axis(estimate), label(parm)


 twoway scatter   axis estimate, ///
            xline(1) ylab(1/3, valuelabel angle(0)) ||    ///
       rcap min95 max95 axis, horizontal               ///
            legend(order(1 "point estimate"            ///
                         2 "95% conf. int.") pos(6))   ///
            xtitle("odds ratio") ytitle("")
 *--------------------- end example ---------------------
(For more on examples I sent to the Statalist see:
http://www.maartenbuis.nl/example_faq )

Hope this helps,
Maarten

--------------------------
Maarten L. Buis
Institut fuer Soziologie
Universitaet Tuebingen
Wilhelmstrasse 36
72074 Tuebingen
Germany


http://www.maartenbuis.nl
--------------------------
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index