Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Whether the dichotomous variable be treated as endogenous variable in the path analysis and how?(help)

From   Maarten buis <>
Subject   Re: st: Whether the dichotomous variable be treated as endogenous variable in the path analysis and how?(help)
Date   Sun, 13 May 2007 08:28:36 +0100 (BST)

--- Yan Cheng <> wrote:
> I have a a dichotomous variable as endogenous variable in the path
> analysis, sex(0/1), I wrote the following syntax, is it right? Could
> you please provide me some advances?
> pathreg (knowledge exogenous_vars) /*
> */ (attitude knowledge exegenous_vars) /*
> */ (sex attitude knowledge exogenous_vars)

The sex equation will estimate a linear probability model, and those
are now only used for instruction and not for analysis. If you want to
publish this than the chances are very high that at least one referee
will fall over this. So instead of -regress- you should use something
like -logit- in the final equation. I am pretty sure -gllamm- can
estimate a model like this. An alternative that might be good (but no
guarantees) is estimating the model manually (with separate -regress-
commands) and replacing the final command with logit. You can get the
closest thing to standardized coefficient using the -listcoef- command
which is part of the -spost- package (to install type -findit spost-
and follow the instructions). See the example below.

*------------ begin example --------------
sysuse auto, clear

/*make rep78 a dummie*/
recode rep78 1/3=0 4/5=1 

pathreg (price foreign) /*
     */ (mpg price foreign weight) /*
     */ (rep78 mpg price foreign)

/*make an indicator variable touse that */
/*indicates wheter the case is observed*/
/*on all relevant variables*/
tempvar touse
gen `touse' = !missing(price, foreign, /*
                    */ mpg, weight, rep78)

/*Separate regression reproduce the results from -pathreg-*/
reg price foreign if `touse', beta
reg mpg price foreign weight if `touse', beta
reg rep78 mpg price foreign if `touse', beta

/*replacing the final command with logit*/
logit rep78 mpg price foreign if `touse'

/*look at the column bStdXY*/
listcoef, std
*------------ end example --------------------
(For more on how to use examples I sent to the Statalist, see: )

Hope this helps,

Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands

visiting address:
Buitenveldertselaan 3 (Metropolitan), room Z434

+31 20 5986715

Yahoo! Mail is the world's favourite email. Don't settle for less, sign up for
your free account today* 
*   For searches and help try:

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