options(object.size=Inf) rm(list=ls()) ##This runs in Splus 3.4 ##TESTING SIMULATED DATA ##function definitions source("functions.S") source("constants.S") VERBOSE <- T means <- array(0,dim=c(NN,length(alphas),length(DFS2),length(DFS),11)) ##temporary storage for estimates sdcheck <- rep(0,NN) cat("dist of x=",Distributionx,"ind=",Independentx,"dist of y=",Distributiony,"Linear=",Linear,"N=",n,"NN=",NN,"\n\n") for(i in 1:5){ source("model-generation.S") source("data-generation.S") truep <- ilogit(trueh+truealpha*Q(Y)) cat("range of truef1:",signif(range(truef1),4),"range of truef2:",signif(range(truef2),4),"range of truef:",signif(range(truef),4),"\n") cat("range of trueh1:",signif(range(trueh1),4),"range of trueh2:",signif(range(trueh2),4),"range of trueh:",signif(range(trueh),4),"\n") cat("range of CD4",signif(range(CD4)),"range of Age",signif(range(Age)),"\n") cat("mean and rage of Y", mean(Y),range(Y),"\n") cat("range of p:",range(truep),"\n") r <- 1-rbinom(n,1,truep) ##this is the simulated data (missing is 0) cat("prop not missing:",mean(r),"\n") }