tags:

views:

32

answers:

0

Dear all,

I'm doing coarsened exact matching on an imputed dataset. To validate I do bootstrapping of the results from cem. However I'm unable to get boot.ci output to work. I get the error msg

Error in bca.ci(boot.out, conf, index[1L], L = L, t = t.o, t0 = t0.o, : estimated adjustment 'a' is NA

The object is there but for some reason I cannot get the bias corrected result.

library(boot)
library(cem)
library(Amelia)

am.bo<-function(data,ind){
data<-data[ind,]
a9<-amelia(data,ords=c("gck","gc.m","gc.e","gc.v"),id=c("as2","d30"))
os<-a9$imputations[1:5]
os2<-cem(treatment="as2",datalist=os,data=data,drop="bc")
os3<-att(os2,gck~bc,data=os)
print(os3,T)->g
intercept<-g[1,1]
bac<-g[1,2]
vec<-c(intercept,bc)
return(vec)
}

dlply(a4,.(as),function(x) boot(x,am.bo,R=30))->bootas_gcadm


lapply(bootas_gcadm,boot.ci)

Basically everything is running smoothly, except that I cannot for get the bca bootstrap CI.

Regards,

/M