# Survival Analysis in R and Cox Proportional Hazard Model

I am trying to do a coxph model with the following code:

coxph.fitR <- coxph(Surv(Survival_test$Recency, Survival_test$Event) ~ Survival_test$Group)  My dataset looks as following: I have a Vector with the times, whether the event occured or not and which Group the individual is associated with. My goal is to find the difference between the two Groups: structure(list(User = 1:10, Recency = c(30L, 9L, 6L, 77L, 5L, 3L, 46L, 55L, 64L, 328L), Event = c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), Group = c("A", "B", "A", "B", "B", "B", "A", "B", "A", "B")), .Names = c("User", "Recency", "Event", "Group"), class = c("tbl_df", "tbl", "data.frame"), row.names = c(NA, -10L), spec = structure(list( cols = structure(list(User = structure(list(), class = c("collector_integer", "collector")), Recency = structure(list(), class = c("collector_integer", "collector")), Event = structure(list(), class = c("collector_integer", "collector")), Group = structure(list(), class = c("collector_character", "collector"))), .Names = c("User", "Recency", "Event", "Group" )), default = structure(list(), class = c("collector_guess", "collector"))), .Names = c("cols", "default"), class = "col_spec"))  I get the following result and my question: Why do i only get values for the group B and not also for Group A? Or how can i interpret those values? > coxph.fitR Call: coxph(formula = Surv(Survival_test$Recency, Survival_test$Event) ~ Survival_test$Group)

coef exp(coef) se(coef)     z    p
Survival_test\$GroupB -0.387     0.679    0.717 -0.54 0.59

Likelihood ratio test=0.29  on 1 df, p=0.591
n= 10, number of events= 10


Excuse me if this is a very obvious question!

• Group A is the reference category. Search this site for "reference category" for many answers. – mdewey Aug 9 '17 at 15:14

• Is this the same case when there is the category listed but with a value NA and Coefficients:(1 not defined because of singularities) ? – svnnf Aug 11 '17 at 8:09