Say you have a Cox proportional hazards model with 1 covariate, gender (coded 0 and 1 for male and female). The R summary will give a likelihood ratio test, and p < 0.05 indicates that the survival distribution is different for the two genders, because it's essentially comparing the "null" baseline model with gender = 0 to the "full" model where you specify gender is female. (At least this is my understanding).
Now say you introduce a continuous height variable.
- How do you test whether the survival distribution differs between males and females after controlling for height? I think one way is for you fit two models, one with both height and gender, and one with just height, and doing a likelihood ratio test between the two, but it's not like gender is 0 in one model and 1 in the other; gender is either 0 or 1 in each model. It seems like it wouldn't test for a difference between male/female at all, because if you compare both models when gender is 0, then you just have the same model.
- I've read that the LR test can help you figure out if an interaction term is needed. How would that be accomplished with this simple example? Which models do you compare to calculate the statistic in this case?
Any help would be appreciated!