[R] SURVDIFF()

Medic m@iliP@dpo@t @ending from gm@il@com
Sat Jan 12 10:18:13 CET 2019


How to note (in code) a few (!) adjusting covariates for cox
regression. I had an example for one covariate, and tried (according
to my own understanding) two variantes of code  (pls, see below), and
got ... a different p-value. What is the right code? Many thanks!!!

(1)
survdiff (Surv(survt,status)~clinic+strata(prison, dose, gender),data=addicts)
N Observed Expected (O-E)^2/E (O-E)^2/V
clinic=1 163      122    106.2      2.35        14
clinic=2  75       28     43.8      5.70        14
Chisq= 14  on 1 degrees of freedom, p= 2e-04

(2)
survdiff (Surv(survt,status)~clinic+strata(prison+dose+gender),data=addicts)
N Observed Expected (O-E)^2/E (O-E)^2/V
clinic=1 163      122    106.2      2.35      12.1
clinic=2  75       28     43.8      5.69      12.1
Chisq= 12.1  on 1 degrees of freedom, p= 5e-04



More information about the R-help mailing list