Timeline for How to calculate Hazard ratio if there are more than two Kaplan-Meier curves
Current License: CC BY-SA 4.0
8 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Apr 6, 2019 at 12:48 | vote | accept | Statistical_Research | ||
Apr 6, 2019 at 12:48 | vote | accept | Statistical_Research | ||
Apr 6, 2019 at 12:48 | |||||
Apr 5, 2019 at 18:03 | comment | added | Björn | They are indeed all with reference to a reference category, I would confirm in the documentation how this is chosen by default (alphabetical? Data order?). | |
Apr 5, 2019 at 17:45 | comment | added | Huy Pham | It sounds like this might be helpful | |
Apr 5, 2019 at 14:16 | comment | added | Statistical_Research | To clarify it further, 1,2,3 and 4 are names of clusters.....I could have used A,B,C, and D... So, you are right in using as.factor. ...Thanks for pointing that out. I used as.factor(clusters) and it is now giving 3 hazard ratios as : as.factor(cluster2) = 3.4772 , as.factor(cluster3) = 0.7027, as.factor(cluster4) = 1.5584. Am I correct in assuming that all these hazard ratios have been calculated w.r.t. hazard of cluster 1.. | |
Apr 5, 2019 at 12:58 | comment | added | Björn | I suspect the coxph function thinks you are giving a continuous variable ranging from 1 to 4 and is estimating the hazard ratio for the increase by 1 unit in the clusters variable. This really only makes sense if this is a continous variable, where a difference of 1 from 1 to 2 means the same thing as the difference from 3 to 4 and son on, and you think that the effect on the log hazard ratio should reasonably be twice that when going from 1 to 3 or 2 to 4. From how you describe this, I assume that is not waht is going on and you may want coxph(Surv(Survival,Death) ~ as.factor(clusters)). | |
Apr 5, 2019 at 9:56 | comment | added | Statistical_Research | my confusion arises from the following implementation in R: Suppose, I have the following line of code: fitcox <- coxph(Surv(Survival,Death) ~ clusters, data = data).... Here "clusters" is a vector with 30 values as 1, 30 values as 2 ,30 values a 3 and 30 values as 4. The Kaplan-Meier graph consists of 4 plots ; one for each cluster. When I run the above command, the hazard ratio comes out to be 1.3154 (i.e. exp(coef) in R).What does that mean?I mean I have 4 groups but hazard ratio is supposed to be between 2 groups only. What does R mean by 1.3154.. | |
Apr 5, 2019 at 5:15 | history | answered | Björn | CC BY-SA 4.0 |