Re: [R] X matrix deemed to be singular in counting process coxph

2007-10-22 Thread caspar
Dear Terry Thanks for your reply, I guess then including only the interaction term only should make sense, since a difference in group 1 between t=0 and t=1 is already taken into account in the baseline (all coefficients set to zero). My second group as I understand it should have an exp(coef_g

Re: [R] X matrix deemed to be singular in counting process coxph

2007-10-19 Thread Terry Therneau
What you have is a slightly more subtle variant of the following: library(survival) data(lung) mydata <- cbind(lung, newvar =2) coxph(Surv(time, status) ~ ph.karno + newvar, mydata) coef exp(coef) se(coef) z p ph.karno -0.0164 0.984 0.00585 -2.81

[R] X matrix deemed to be singular in counting process coxph

2007-10-18 Thread caspar
Dear all, I have a question with respect to counting process formulation of the coxph(survival) model. I have two groups of observations for which I have partitioned each observation into two distinct time intervals, namely, entry day till day 13, and day 13 till death or censorship day (of co