Dear R-experts, Here below my R code. Using "bca" in the boot.ci function at the end of my R code works perfectly. Using "perc" and "basic" perfectly works as well. But using "norm", my R code does not work anymore. Is it possible to solve that problem and to make my R code work ?
################################################ library(boot) s<- sample(178:798, 10000, replace=TRUE) mean(s) N <- 100 out <- replicate(N, { a<- sample(s,size=5) mean(a) dat<-data.frame(a) med<-function(d,i) { temp<-d[i,] mean(temp) } boot.out <- boot(data = dat, statistic = med, R = 10000) boot.ci(boot.out, type = "norm")$norm[, 4:5] }) mean(out[1,] < mean(s) & mean(s) < out[2,]) ################################################ ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.