# import and attach the data example
data(dataDIVAT3)
# A subgroup analysis to reduce the time needed for this exemple
dataDIVAT3 <- dataDIVAT3[1:400,]
# The ROC curve to evaluate the crude capacities of the recipient age for the
# prognosis of post kidney transplant mortality (we ignore the censoring process)
roc1 <- roc.binary(status="death", variable="ageR", confounders=~1,
data=dataDIVAT3, precision=seq(0.1,0.9, by=0.1) )
# The corresponding ROC graph with color and symbols
plot(roc1, type="b", xlab="1-specificity", ylab="sensibility", col=2, pch=2)
Run the code above in your browser using DataLab