# Required package: 'boot' house=read.csv('http://webpages.uidaho.edu/~renaes/Data/msa%20housing.csv',header=T) head(house) library(boot) sample_mean = function(data, indices){ d = data[indices, ] bar = mean(d$mnth2002) return(bar) } results <- boot(data=house, statistic=sample_mean, R=1000) plot(results) boot.ci(results, type="norm")