Dear stata listers
I'm using stata to analyse time-to-event data. Specifically, I'm trying to relate licensing data to merger and acquisition events in the bio-pharmaceutical industry.
To that aim, I use the Cox PH model, and I've managed to set up and analyse the data in stata (v 14.2) by means of the commands listed below - an excerpt of the datafile can be found in attachment.
The problem I'm facing is related to the analysis of a certain covariate, i.e. the total asset value of the licensees. This value is not constant and is dependent on the licensee.
My question is now: how to correctly implement this specific covariate in the existing Cox PH model.
I've searched in the internet but I haven't found a solution to this particular problem.
Any help/suggestions would be highly appreciated.
Many thanks in advance
Alex (stata 14.2) [ATTACH]temp_12751_1544367960848_705[/ATTACH]
PS In the dataset, I've already defined an additional ID (value) for each unique licensee (named: Licensee ID), the total asset value of the licensee is in a column named Licensee Total Assets (th USD).
*Define variables for Survival Analysis
global time Date
global event M_A
global id ID
global xlist LicenseCumulAll
gen PeriodStart = mdy(1, 1, 2000)
* Set data as survival time
stset $time, id($id) failure($event) origin(time PeriodStart) scale(365.25)
* Cox proportional hazard model
stcox $xlist, cluster(ID)
Related Posts with Cox proportional hazards model a non constant covariate
Accessing Files Created within SubprogramI am writing a Stata .ado program that performs the same subroutine many times. As such, I would lik…
Formatting datetime from one format to another in same variableHello everyone! I am facing some issues with my timestamp variable. The data that I have received f…
How to weight the Gini coefficient decomposition?hi all, i want the Gini coefficient decomposition in Lerman-Yitzhaki's method. but "descogini" does…
Overlay graphics in Stata / Export graphic with transparent background?I have 2 graphics (attached, .gph and .png versions of each) that I created with a user-written comm…
Fixed Effects: how to report in a tableHi all, I would like to ask a question, please, about how to report a fixed effects regression in a…
Subscribe to:
Post Comments (Atom)
0 Response to Cox proportional hazards model a non constant covariate
Post a Comment