bootstrapping code in R doesn't work? -
so ready jump off building because cannot figure out code life. everytime run it, standard error of 0 (bias=0 too) i'm doing wrong because it's using same sample when want 1000 iterations.
i want aic of model these samples. i've created data frame , named "d."
here code:
bootaic<-function(d, idx){ d2<-d[idx,] fit<-coxph(surv(time,infection) ~ x48fl + x55fl, method="efron", data=d) return(aic(fit)) } bootf<-boot(data=d,statistic=bootaic,r=1000)
what wrong. appreciate , help, novice bootstrapping , suck @ coding.
Comments
Post a Comment