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: Survival Analysis: How to solve the problem of endogeneity of an explanatory variable


From   Steve Samuels <[email protected]>
To   [email protected]
Subject   Re: st: Survival Analysis: How to solve the problem of endogeneity of an explanatory variable
Date   Wed, 20 Nov 2013 14:19:45 -0500

I should have been a little more careful in the person-time definitions.
See below where I replace "<" with "<=" in the first ptime equation.

SS


Ingrid:

I've no personal experience with endogeneity and selection models, but
Bartus's presentation about -cmp- inspired me to look into Stata 13's
Structual Equation Modeling (SEM) features, surely the new features
that he was alluding to.

It turns out that -gsem- can fit a piecewise exponential model via the
equivalent Poisson regression.
(http://stats.stackexchange.com/questions/2092/relationship-between-
poisson-and-exponential-distribution) Therefore piecewise exponential
regression can be part of a system of linked equations. In other words,
you don't need to rely on the lognormal distribution for the spell data.

Here is a simple example of linked piecewise exponential and logit
models. You can elaborate as needed, for example by adding interactions
of covariates and time to the -poisson- equation. I use Stata's survival
commands to set up the spell data and to demonstrate that the piecewise
Poisson and exponential regressions are equivalent.

Note that Selection and treatment effects models are demonstrated in
examples 45f and 45g of the SEM manual.


Steve
[email protected]

*************CODE BEGINS*************
webuse brcancer,clear
rename censrec event

/* Convert from days to years */
gen ty = rectime/365.25
stset ty, failure(event) id(id)

/* stsplit to one year intervals */
stsplit tx , every(1)
replace event=0 if event==.

/* calculate person-time in each interval */
gen ptime = 0 if ty<= tx
replace ptime = 1 if  ty>=tx+1
replace ptime = ty - tx if ty> tx & ty< tx +1

drop if tx == 7 /* no events */

/* Piecewise exponential & Poisson: Same */
streg ibn.tx, nocons d(exponential)
poisson event ibn.tx, nocons exp(ptime)  irr

/* Now GSEM linked equations */
gsem  ///
(event <- ibn.tx hormon, poisson exp(ptime) nocons) ///
(hormon <- x7, f(binomial) link(logit))
estat eform  event hormon
**************CODE ENDS**************


> 
> 
> On Nov 19, 2013, at 10:32 AM, Bartus Tamás wrote:
> 
> Dear Ingrid,
> 
> If you find the assumption of lognormal distribution realistic in your resarch, you might check the following
> presentation:
> 
> http://www.stata.com/meeting/germany12/abstracts/desug12_bartus.pdf 
> 
> 
> You might also be interested in the new features of Stata 13.1 which were advertised recently on the list.
> 
> 
> 
> (The above presentation does not deal with multispell data but I currently work on this extension)
> 
> 
> 
> Tamas
> 
> 
> 
> 

On 13/11/19, Ingrid Hohenleitner <[email protected]> wrote: 
> Dear community,
> 
> I am working on a problem in survival analysis, trying to find out the
> difference in transition rate from unemployment to employment (<- time to
> event), between two groups: people who are sanctioned, and those who are not
> sanctioned. Where “sanctioned” means that the amount of unemployment
> benefit payment is reduced for a certain period as a punishment, for example
> if the unemployed does not show enough effort to search a job. The
> probability of being sanctioned as well as the probability to find a job
> depends on unobserved characteristics like a person’s attitude to work.
> 
> Thus, I face the problem that the variable “sanctioned” is dependent upon
> observed as well as of unobserved determinants. And furthermore, the
> explanatory variable “sanctioned” is endogenous and the process of being
> sanctioned is not exogenous with respect to the transition from unemployment
> to employment.
> 
> I am not an expert in STATA and was wondering how to deal with this problem.
> Should I handle the problem by simultaneously modeling two parallel
> processes, the sanctioning and the transition-into-employment process; or by
> some other way?
> In either case, can you suggest me the inbuilt STATA commands, or freely
> available routines that I can use to address this problem.
> 
> I would be very grateful for your help,
> Ingrid Hohenleitner
> 
> 
> 
> Hamburgisches WeltWirtschaftsInstitut gemeinnützige GmbH (HWWI)
> Hamburg Institute of International Economics (HWWI)
> Heimhuder Str. 71
> 20148 Hamburg
> Tel +49-(0)40-340576-338
> Fax +49-(0)40-340576-776
> Internet: www.hwwi.org
> Email: [email protected]
> 
> Amtsgericht Hamburg HRB 94303
> Geschäftsführer: Prof. Dr. Thomas Straubhaar, Gunnar Geyer
> Umsatzsteuer-ID: DE 241849425
> 
> 
> 
> *
> * 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/
> 
> 
--

Tamás Bartus, PhD
Associate Professor, Deputy Director
Institute of Sociology and Social Policy
Program Director, Doctoral School of Sociology
Corvinus University, Budapest 
1093 Budapest, Közraktár utca 4-6.
Room 424.
Phone: +36-1-482-7301 
Fax: +36-1-482-7348
Homepage: http://web.uni-corvinus.hu/bartus

*
*   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/


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