[R] How to calculate deviance on test data

zmlr jgz02865 at hotmail.com
Sun Mar 25 16:09:23 CEST 2012

Hi all,

If I got a Cox model based on training set, then how should I calculate the
Cox log partial likelihood for the test data?
Actually I am trying to calculate the deviance on test dataset to evaluate
the performance of prediction model, the equation is as follows: D =
-2{L(test)[beta_train] - L(test)[0]}. It means using the beta coefficients
got from training set to calculate the likelihood of test data. I know I can
got log likelihood for training model, but how to get it for test data?
Any package or function can do that? 

View this message in context: http://r.789695.n4.nabble.com/How-to-calculate-deviance-on-test-data-tp4503206p4503206.html
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list