Bootstrap v traditional asymptotic normal assumptions by @ellis2013nz

Wait 5 sec.

[This article was first published on free range statistics - R, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.Today’s just a very short sequel to last week’s post, where I had a look at some very skewed distributions to test the idea that sample sizes sometimes need to be in the tens of thousands for the sample mean to have a normal distribution. Turns out they do.I had a bit of unfinished business at the back of my mind, which was “would a bootstrap confidence interval do any better?”. Hence today’s new set of simulations.I compared the coverage of a 95% confidence interval for the mean constructed the traditional way—like they teach it in basic stats courses—from a few heavily skewed distributions. I also constructed a 95% confidence interval using the bias-corrected and adjusted bootstrap method, which I believe is the best candidate to work in a wide variety of bias and skew situations.To skip to the chase, here’s the results. Turns out that a) the bootstrap does indeed do considerably better than just relying on the central limit theorem, particularly with smaller sample sizes; and b) it’s still got coverage a lot less than the 95% we wanted:No surprise here; from what I understand of the history, this is pretty much exactly what the BCa bootstrap was developed for. So we’re on it’s home ground, and it does (relatively) well. But those actual coverage numbers are still well below 95%, for both methods.Here’s the code that did that. It’s very similar to the one from a few days ago.library(tidyverse)library(actuar)library(glue)library(scales)library(boot)# set the below to TRUE if running for the first timerun_sims