[R] coxph: how to define interaction terms?

rm rm at wippies.se
Mon Oct 28 10:00:30 CET 2013

I’m trying to set up Cox Proptional Hazard model with interactions between
time and the covariates (which are categorical). The problem that I face is
that how to define the interactions, i.e. “x+cutStart:x”, properly.

The code below illustrates the problem. R gives the error message ” X matrix
deemed to be singular”, because “x+cutStart:x” includes too many
combinations of the dummies in the model. 

Any help is much appreciated!


View this message in context: http://r.789695.n4.nabble.com/coxph-how-to-define-interaction-terms-tp4679162.html
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list