Hello,


Then the C-stat from the model is different from the computed one
using rcorr.cens


library(rms)

n <- 1000

set.seed(17)

age            <- rnorm(n, 50, 10)

blood.pressure <- rnorm(n, 120, 15)

cholesterol    <- rnorm(n, 200, 25)

sex            <- factor(sample(c('female','male'), n,TRUE))

ch <- cut2(cholesterol, g=40, levels.mean=TRUE) # use mean values in
intervals

modx <- lrm(ch ~ age)

NewDat <- data.frame(age)


c(modx$stats["C"],

  rcorr.cens(predict(modx,newdata=NewDat), ch)["C Index"],

  rcorr.cens(predict(modx,newdata=NewDat,type="fitted")[,1], ch)["C Index"],

  rcorr.cens(predict(modx,newdata=NewDat,type="fitted")[,2], ch)["C Index"])


Many Thanks

Linda

	[[alternative HTML version deleted]]

