gravatar for ronaldmumbere012

2 hours ago by

hello,

i am comparing the coxph model with the quartile regression model model using r, However the soft is showing the error massage Error in supsmu(1 - g$surv, g$time) : number of observations in 'x' and 'y' must match. some on help me fix the error.

this is my code
Model2<-crq(formula=Surv(survivaltime)~ sex + age + hivstatus + smoking + alcohol + new_age, tau=c(0.2,0.4,0.6,0.8), data=mydata ,method="Portnoy")
summary(Model2, 1:13/240)
plot(summary(Model2, 1:13/240))
SModel2<-(summary(Model2))
PHit<-coxph(Surv(survivaltime,status)~ sex + age + hivstatus + smoking + alcohol+new_age , data=mydata ,id=no)
PHit
myplot<-plot.summary.crqs
fix(myplot)
myplot(SModel2, CoxPHit=PHit)



Source link