# NOT RUN {
set.seed(1)
yd <- data.frame(sample(c(0,1),30,replace=TRUE))
colnames(yd) <- "remiss"
set.seed(4)
xd <- data.frame(matrix(c(round(rnorm(100,0,2),2),round(rnorm(140,2,4),2),
sample(c(1,0),30,replace=TRUE),sample(1:80,30,replace=TRUE)),30,10))
colnames(xd) <- c(paste("X",1:8,sep=""),"gender","age")
yx <- cbind(yd,xd)
y <- "remiss"
comVar <- paste("X",1:3,sep="")
fm <- paste(y,"~",paste0(comVar,collapse = "+"),sep="")
model <- glm(fm,yx,family="binomial")
scoretest(model, as.matrix(yx[,4]))
# }
Run the code above in your browser using DataLab