cox-regression

Stratified log-rank test in R for counting process form data?

微笑、不失礼 提交于 2019-12-02 03:02:02
问题 Background : at half-year follow up times for 4y, patients may switch to a different medication group. To account for this, I've converted survival data into counting process form. I want to compare survival curves for medication groups A, B, and C. I am using an extended Cox model but want to do pairwise comparisons of each hazard function or do stratified log-rank tests. pairwise_survdiff throws an error because of the form of my data, I think. Example data : x<-data.frame(tstart=rep(seq(0

Stratified log-rank test in R for counting process form data?

北城余情 提交于 2019-12-02 02:32:51
Background : at half-year follow up times for 4y, patients may switch to a different medication group. To account for this, I've converted survival data into counting process form. I want to compare survival curves for medication groups A, B, and C. I am using an extended Cox model but want to do pairwise comparisons of each hazard function or do stratified log-rank tests. pairwise_survdiff throws an error because of the form of my data, I think. Example data : x<-data.frame(tstart=rep(seq(0,18,6),3),tstop=rep(seq(6,24,6),3), rx = rep(c("A","B","C"),4), death=c(rep(0,11),1)) x Problem : When

coxph() X matrix deemed to be singular;

南楼画角 提交于 2019-11-30 11:36:16
I'm having some trouble using coxph(). I've two categorical variables:"tecnologia" and "pais", and I want to evaluate the possible interaction effect of "pais" on "tecnologia"."tecnologia" is a variable factor with 2 levels: gps and convencional. And "pais" as 2 levels: PT and ES. I have no idea why this warning keeps appearing. Here's the code and the output: cox_AC<-coxph(Surv(dados_temp$dias_seg,dados_temp$status)~tecnologia*pais,data=dados_temp) Warning message: In coxph(Surv(dados_temp$dias_seg, dados_temp$status) ~ tecnologia * : X matrix deemed to be singular; variable 3 > cox_AC Call: