helper_f function

Calculate bootstrapping results for one sample