confint_1group

A range of functions to compute bootstraps for a single sample.

source

summary_ci_1group


def summary_ci_1group(
    x:np.array, # An numerical iterable.
    func, # The function to be applied to x.
    resamples:int=5000, # The number of bootstrap resamples to be taken of func(x).
    alpha:float=0.05, # Denotes the likelihood that the confidence interval produced _does not_ include the true summary statistic. When alpha = 0.05, a 95% confidence interval is produced.
    random_seed:int=12345, # `random_seed` is used to seed the random number generator during bootstrap resampling. This ensures that the confidence intervals reported are replicable.
    sort_bootstraps:bool=True, args:VAR_POSITIONAL, kwargs:VAR_KEYWORD
): # `summary`: float.
    The outcome of func(x).
`func`: function.
    The function applied to x.
`bca_ci_low`: float
`bca_ci_high`: float.
    The bias-corrected and accelerated confidence interval, for the
    given alpha.
`bootstraps`: array.
    The bootstraps used to generate the confidence interval.
    These will be sorted in ascending order if `sort_bootstraps`
    was True.

Given an array-like x, returns func(x), and a bootstrap confidence interval of func(x).


source

compute_1group_bias_correction


def compute_1group_bias_correction(
    x, bootstraps, func, args:VAR_POSITIONAL, kwargs:VAR_KEYWORD
):

Call self as a function.


source

compute_1group_bootstraps


def compute_1group_bootstraps(
    x, func, resamples:int=5000, random_seed:int=12345, args:VAR_POSITIONAL, kwargs:VAR_KEYWORD
):

Bootstraps func(x), with the number of specified resamples.


source

compute_1group_acceleration


def compute_1group_acceleration(
    jack_dist
):

Returns the accaleration value based on the jackknife distribution.


source

compute_1group_jackknife


def compute_1group_jackknife(
    x, func, args:VAR_POSITIONAL, kwargs:VAR_KEYWORD
):

Returns the jackknife bootstraps for func(x).


source

create_bootstrap_indexes


def create_bootstrap_indexes(
    array, resamples:int=5000, random_seed:int=12345
):

Given an array-like, returns a generator of bootstrap indexes to be used for resampling.