Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: interaction without main effects


From   "A.M. Vos" <[email protected]>
To   [email protected]
Subject   Re: st: interaction without main effects
Date   Wed, 15 Jan 2003 17:21:46 +0100

oops, sorry!
I thought I was answering at Johns own e-mail adress.
However, what I state below is that Johns solution worked, so thanks.

Annelies

"A.M. Vos" wrote:
> 
> Bedankt John, dit werkt wel.
> Overigens staat er een heel klein foutje in help desrep: "Aso see" ipv
> also...
> Maar ja, misschien vallen alleen Nederlanders daarover, niet echt
> belangrijk dus.
> Groet, Annelies
> 
> John Hendrickx wrote:
> >
> > Typing i.agegrp|durastay will create dummmies for the main effect of
> > agegrp and interactions between agegrp and durastay as a continuous
> > variable, but no main effects of durastay. But that isn't what the
> > original poster wanted.
> >
> > You can use -desmat- for problems like this:
> >
> > desmat: poisson patient origin age.durstay, exp(ptime)
> >
> > This will estimate a model with main effects for origin and an
> > interaction between age and durstay, but no main effects of age and
> > durstay. But what you're perhaps really interested in is
> >
> > desmat: poisson patient origin age durstay age3.durstay3, exp(ptime)
> >
> > Where age3 and durstay3 are the variables recoded to 3 categories.
> >
> > The latest version of -desmat- is available at SSC. Type -ssc
> > describe desmat- for more information.
> >
> > Hope this helps,
> > John Hendrickx
> >
> > --- Jonathan Beck <[email protected]> wrote:
> > > typing i.agegrp|durastay (without "i."before durastay) should give
> > > you main effects for durastay plus the interactions with agegrp,
> > > but
> > > no main effects for agegroup.
> > >
> > > I suppose you read the right thing in help, but got an error by
> > > translating it to your varnames.
> > >
> > > Jonathan
> > >
> > > > Dear all,
> > > > I might just look at the wrong place, but...
> > > > I'm performing a poisson regression like:
> > > >  xi: poisson patient i.origin i.age i.durstay, exp(ptime)
> > > > with 7 agegroups and 9 groups for durstay.
> > > > I want to add an interaction between age and durstay, defined as
> > > > i.agegrp*i.durastay, for which I reallocated agegroups and
> > > durstay
> > > > groups to broader categories 3*3. Now of course, the only extra
> > > output
> > > > I'd like to see is the interactions, not the main effects.
> > > >
> > > > The only thing I could find in "help" is:
> > > > i.varname1|varname3     creates dummies for categorical variable
> > > > varname1 and includes continuous variable varname3:  all
> > > interactions
> > > > and main effect of varname3, but not main effect of varname1.
> > > >
> > > > So I conclude from that, that if I would do i.agegrp|i.durastay,
> > > I would
> > > > get the interactions and the main effect of durastay? That
> > > doesn't
> > > > really help, so what character should be used for only
> > > interaction and
> > > > no main effect? the FAQ's and websearch didn't really guide me to
> > > the
> > > > right direction too.
> > > > I use stata 7
> > > >
> > > > Thanks for any help!
> > > > Annelies
> > > > --
> > > > A.M. Vos
> > > > dept. of Public Health
> > > > Erasmus MC
> > > > University Medical Center Rotterdam
> > > > P.O. Box 1738
> > > > 3000 DR Rotterdam
> > > > The Netherlands
> > > > Tel: +31 (10) 4087502
> > > > Fax: +31 (10) 4089449
> > > > email: [email protected]
> > > > *
> > > > *   For searches and help try:
> > > > *   http://www.stata.com/support/faqs/res/findit.html
> > > > *   http://www.stata.com/support/statalist/faq
> > > > *   http://www.ats.ucla.edu/stat/stata/
> > >
> > >
> > > *
> > > *   For searches and help try:
> > > *   http://www.stata.com/support/faqs/res/findit.html
> > > *   http://www.stata.com/support/statalist/faq
> > > *   http://www.ats.ucla.edu/stat/stata/
> >
> > __________________________________________________
> > Do you Yahoo!?
> > Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
> > http://mailplus.yahoo.com
> > *
> > *   For searches and help try:
> > *   http://www.stata.com/support/faqs/res/findit.html
> > *   http://www.stata.com/support/statalist/faq
> > *   http://www.ats.ucla.edu/stat/stata/
> 
> --
> A.M. Vos
> dept. of Public Health
> Erasmus MC
> University Medical Center Rotterdam
> P.O. Box 1738
> 3000 DR Rotterdam
> The Netherlands
> Tel: +31 (10) 4087502
> Fax: +31 (10) 4089449
> email: [email protected]
> *
> *   For searches and help try:
> *   http://www.stata.com/support/faqs/res/findit.html
> *   http://www.stata.com/support/statalist/faq
> *   http://www.ats.ucla.edu/stat/stata/

-- 
A.M. Vos
dept. of Public Health
Erasmus MC
University Medical Center Rotterdam
P.O. Box 1738
3000 DR Rotterdam
The Netherlands
Tel: +31 (10) 4087502
Fax: +31 (10) 4089449
email: [email protected]
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index