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]

RE: st: comparing coefficients


From   Richard Williams <richardwilliams.ndu@gmail.com>
To   statalist@hsphsun2.harvard.edu, "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   RE: st: comparing coefficients
Date   Thu, 10 Jan 2013 10:29:17 -0500

At 04:41 AM 1/10/2013, John Stymans wrote:
Dear Richard,

many thanks for your comments.

You are right, I use the oglm command with store, not ologit.

Best,

John


Incidentally, I think the optimal way to do the test you want (which requires gologit2 from SSC) would be something like

use "http://www.indiana.edu/~jslsoc/stata/spex_data/ordwarm2.dta";, clear
gen maleyr89 = male * yr89
gen malewhite = male*white
gen maleage = male*age
gen maleed = male*ed
ologit warm i.yr89 i.white c.age c.ed if male==0, nolog
ologit warm i.yr89 i.white c.age c.ed if male==1, nolog
gologit2 warm male yr89 white age ed maleyr89 malewhite maleage maleed, npl(male) lrf
test maleyr89 malewhite maleage maleed

The above gologit2 command allows the cutpoints to differ across groups (similar to allowing constants to differ across groups). You can see that it is producing the same results as the separate groups ologits. Then you can test whether the interaction terms significantly differ from 0.

But again, I am not crazy about doing the test. Or at least you have to understand what it means. It could come up significant because the coefficients differ across groups. Or it could come up significant because the amount of residual variability differs across groups.

----------------------------------------
> Date: Wed, 9 Jan 2013 20:02:11 -0500
> To: statalist@hsphsun2.harvard.edu; statalist@hsphsun2.harvard.edu
> From: richardwilliams.ndu@gmail.com
> Subject: Re: st: comparing coefficients
>
> At 07:07 AM 1/9/2013, David Hoaglin wrote:
> >John,
> >
> >What's wrong with including both genders in a single model and
> >expanding the list of predictors to include gender and the interaction
> >of gender with each of the current predictors?
>
> Actually, that has some problems of its own. Suppose you ran
>
> use "http://www.indiana.edu/~jslsoc/stata/spex_data/ordwarm2.dta";, clear
> reg warm i.yr89 i.white c.age c.ed if male==0
> reg warm i.yr89 i.white c.age c.ed if male==1
> reg warm i.male##(i.yr89 i.white c.age c.ed)
>
> It isn't hard to see that the last model with interactions gives you
> the exact same results as the 2 groups run separately. Things are
> just parameterized differently.
>
> But if instead you run
>
> ologit warm i.yr89 i.white c.age c.ed if male==0, nolog
> ologit warm i.yr89 i.white c.age c.ed if male==1, nolog
> ologit warm i.male##(i.yr89 i.white c.age c.ed), nolog
>
> You see the final model does not give exactly the same results as the
> first two models.
>
> Why not? In the final ologit model, you are allowing all the
> variables to have different effects in each group. BUT, you are
> constraining the cut points to be the same for each group, whereas
> when you run the model separately for the two groups the cutpoints
> can differ. That may not be a bad assumption to make, but nonetheless
> it is an assumption.
>
> Probably more important problems are outlined at
> http://www3.nd.edu/~rwilliam/xsoc73994/L31.pdf. The key issue is
> that, unless the two groups have the same residual variability, tests
> of equality across groups are distorted.
>
> The more I work with ordinal models, the more I think you should do
> everything you can to get continuous dependent variables. There are a
> lot of things you can do in OLS regression that don't generalize as
> you would expect to logit and ologit models.
>
> One other point: as far as I know this command from the original post
> is not legitimate, because there is no store option in ologit:
>
> ologit y1 educationmedium educationhigh age income class household
> country if gender=0, or store(step1a)
>
>
> >David Hoaglin
> >
> >On Wed, Jan 9, 2013 at 4:30 AM, John Stymans <johnstymans@hotmail.be> wrote:
> > > Dear Statalist Users,
> > > I have a problem when comparing coefficients across groups.
> > > I am using Stata 12.
> > > I first run an ordered logit model for two groups (males and females).
> > >
> > > ologit y1 i.education age income class household country if
> > gender=0, or store(step1a)
> > > ologit y1 i.education age income class household country if
> > gender=1, or store(step1b)
> > > goal is to compare across gender the effect of education which is
> > a categorical variable with 3 values, hence the use of i..
> > >
> > > when I use suest:
> > >
> > > suest step1a step1b
> > >
> > > test [step1a _y1]i.education=[step1b_y1]i.education
> > >
> > > the command does not work. I am however able to split education
> > in three values an add two of them to the regression (omitting educationlow);
> > >
> > > ologit y1 educationmedium educationhigh age income class
> > household country if gender=0, or store(step1a)
> > > ologit y1 educationmedium educationhigh age income class
> > household country if gender=1, or store(step1b)
> > > and than run suest:
> > >
> > > suest step1a step1b
> > >
> > > test [step1a _y1]loweducation=[step1b_y1]loweducation
> > >
> > > Yet I am unable to compare the difference in significance of
> > education across gender in general. Does anyone know how to solve this issue?
> > >
> > > Many thanks in advance and best regards,
> > >
> > > John
> >*
> >* For searches and help try:
> >* http://www.stata.com/help.cgi?search
> >* http://www.stata.com/support/faqs/resources/statalist-faq/
> >* http://www.ats.ucla.edu/stat/stata/
>
> -------------------------------------------
> Richard Williams, Notre Dame Dept of Sociology
> OFFICE: (574)631-6668, (574)631-6463
> HOME: (574)289-5227
> EMAIL: Richard.A.Williams.5@ND.Edu
> WWW: http://www.nd.edu/~rwilliam
>
> *
> * For searches and help try:
> * http://www.stata.com/help.cgi?search
> * http://www.stata.com/support/faqs/resources/statalist-faq/
> * http://www.ats.ucla.edu/stat/stata/
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/

-------------------------------------------
Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
HOME:   (574)289-5227
EMAIL:  Richard.A.Williams.5@ND.Edu
WWW:    http://www.nd.edu/~rwilliam

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


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