Tell me more ×
Cross Validated is a question and answer site for statisticians, data analysts, data miners and data visualization experts. It's 100% free, no registration required.

What is the $R^2$ value given in the summary of a coxph model in R? For example,

Rsquare= 0.186   (max possible= 0.991 )

I foolishly included it a manuscript as an $R^2$ value and the reviewer jumped on it saying he wasn't aware of an analogue of the $R^2$ statistic from the classic linear regression being developed for the Cox model and if there was one please provide a reference. Any help would be great!

share|improve this question
1  
In most situations where the concept of $R^2$ is extended beyond classical linear regression, it is the squared correlation between the observed values and those predicted under the model. Could that possibly be applicable here? – Macro Jun 19 '12 at 12:54

1 Answer

up vote 5 down vote accepted

Using getS3method("summary","coxph") you can look at how it is calculated.

The relevant code lines are the following:

logtest <- -2 * (cox$loglik[1] - cox$loglik[2])
rval$rsq <- c(rsq = 1 - exp(-logtest/cox$n), maxrsq = 1 - 
        exp(2 * cox$loglik[1]/cox$n))

Here cox$loglik is "a vector of length 2 containing the log-likelihood with the initial values and with the final values of the coefficients" (see ?coxph.object) and cox$n is "number of observations used in the fit".

share|improve this answer
3  
If I'm not mistaken, that's the Cox & Snell pseudo R-squared. For explanation & comparision of various pseudo R-squareds, see ats.ucla.edu/stat/mult_pkg/faq/general/psuedo_rsquareds.htm . – onestop Jun 19 '12 at 14:16

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.