Liking cljdoc? Tell your friends :D

criterium.stats.bootstrap

Bootstrap resampling and confidence interval estimation.

Provides core bootstrap algorithms for statistical inference:

  • bootstrap-sample: Resampling with replacement
  • bootstrap-estimate: Mean, variance and confidence intervals
  • jacknife: Leave-one-out resampling
  • bca-nonparametric: Bias-corrected and accelerated bootstrap
  • bootstrap-bca: Bootstrap with BCa confidence intervals

References:

Bootstrap resampling and confidence interval estimation.

Provides core bootstrap algorithms for statistical inference:
- bootstrap-sample: Resampling with replacement
- bootstrap-estimate: Mean, variance and confidence intervals
- jacknife: Leave-one-out resampling
- bca-nonparametric: Bias-corrected and accelerated bootstrap
- bootstrap-bca: Bootstrap with BCa confidence intervals

References:
- Efron, B., & Tibshirani, R. J. (1993). An introduction to the bootstrap.
- http://lib.stat.cmu.edu/S/bootstrap.funs
raw docstring

assoc-bootstrap-mean-3-sigmaclj

(assoc-bootstrap-mean-3-sigma {:keys [mean variance] :as stats})

Add :mean-plus-3sigma and :mean-minus-3sigma to stats map.

Add :mean-plus-3sigma and :mean-minus-3sigma to stats map.
sourceraw docstring

bca-nonparametricclj

(bca-nonparametric data statistic size alpha rng-factory)

Non-parametric BCa estimate of a statistic on data.

Data must be a DoubleArray or sequence (converted to DoubleArray). The statistic function receives a sorted DoubleArray.

Size bootstrap samples are used. Confidence values are returned at the alpha normal quantiles. rng-factory is a function that returns a random number generator to use for the sampling.

References:

Non-parametric BCa estimate of a statistic on data.

Data must be a DoubleArray or sequence (converted to DoubleArray).
The statistic function receives a sorted DoubleArray.

Size bootstrap samples are used. Confidence values are returned at the
alpha normal quantiles. rng-factory is a function that returns a random
number generator to use for the sampling.

References:
- An introduction to the bootstrap. Efron, B., & Tibshirani, R. J. (1993).
- http://lib.stat.cmu.edu/S/bootstrap.funs for Efron's original implementation.
sourceraw docstring

bca-nonparametric-evalclj

(bca-nonparametric-eval size z-alpha estimate samples jack-samples)

Calculate bootstrap values for given estimate and samples.

Internal function used by bca-nonparametric. samples and jack-samples are sequences of statistic values.

Calculate bootstrap values for given estimate and samples.

Internal function used by bca-nonparametric.
samples and jack-samples are sequences of statistic values.
sourceraw docstring

bootstrapclj

(bootstrap data statistic size rng-factory)

Bootstrap a statistic.

Statistic can produce multiple statistics as a vector, so you can use juxt to pass multiple statistics.

Returns [mean variance [lower upper]] for each statistic.

See: http://en.wikipedia.org/wiki/Bootstrapping_(statistics)

Bootstrap a statistic.

Statistic can produce multiple statistics as a vector, so you can use juxt
to pass multiple statistics.

Returns [mean variance [lower upper]] for each statistic.

See: http://en.wikipedia.org/wiki/Bootstrapping_(statistics)
sourceraw docstring

bootstrap-bcaclj

(bootstrap-bca data statistic size alpha rng-factory)

Bootstrap a statistic with BCa confidence intervals.

Statistic can produce multiple statistics as a vector, so you can use juxt to pass multiple statistics.

Returns a BcaEstimate record with :point-estimate and :estimate-quantiles.

See: http://en.wikipedia.org/wiki/Bootstrapping_(statistics)

Bootstrap a statistic with BCa confidence intervals.

Statistic can produce multiple statistics as a vector, so you can use juxt
to pass multiple statistics.

Returns a BcaEstimate record with :point-estimate and :estimate-quantiles.

See: http://en.wikipedia.org/wiki/Bootstrapping_(statistics)
sourceraw docstring

bootstrap-estimateclj

(bootstrap-estimate sampled-stat)

Mean, variance and confidence interval from bootstrapped samples.

sampled-stat is a sequence of statistic values (converted to DoubleArray).

Returns [mean variance [lower upper]] where the confidence interval uses the bootstrapped statistic's variance.

Mean, variance and confidence interval from bootstrapped samples.

sampled-stat is a sequence of statistic values (converted to DoubleArray).

Returns [mean variance [lower upper]] where the confidence interval
uses the bootstrapped statistic's variance.
sourceraw docstring

bootstrap-sampleclj

(bootstrap-sample data statistic size rng-factory)

Bootstrap sampling of a statistic, using resampling with replacement.

Data must be a DoubleArray or sequence (converted to DoubleArray). The statistic function receives a sorted DoubleArray.

Returns transposed results: if statistic returns a vector, returns a vector of vectors where each inner vector contains all samples for that statistic.

Bootstrap sampling of a statistic, using resampling with replacement.

Data must be a DoubleArray or sequence (converted to DoubleArray).
The statistic function receives a sorted DoubleArray.

Returns transposed results: if statistic returns a vector, returns a vector
of vectors where each inner vector contains all samples for that statistic.
sourceraw docstring

drop-atclj

(drop-at n coll)

Return coll with element at index n removed.

Return coll with element at index n removed.
sourceraw docstring

jacknifeclj

(jacknife data statistic)

Jacknife statistics on data.

Data must be a DoubleArray or sequence (converted to DoubleArray). The statistic function receives a DoubleArray.

Computes the statistic on each leave-one-out sample of the data. Returns transposed results like bootstrap-sample.

Jacknife statistics on data.

Data must be a DoubleArray or sequence (converted to DoubleArray).
The statistic function receives a DoubleArray.

Computes the statistic on each leave-one-out sample of the data.
Returns transposed results like bootstrap-sample.
sourceraw docstring

scale-bootstrap-estimateclj

(scale-bootstrap-estimate estimate scale)

Scale a BcaEstimate by the given scale factor.

Scale a BcaEstimate by the given scale factor.
sourceraw docstring

scale-bootstrap-statclj

(scale-bootstrap-stat scale-f stat)

Scale a bootstrap stat using the given scale function.

Scale a bootstrap stat using the given scale function.
sourceraw docstring

scale-bootstrap-valuesclj

(scale-bootstrap-values stats f)

Apply function f to all values in stats map.

Apply function f to all values in stats map.
sourceraw docstring

stats-fnclj

(stats-fn fs)

Combine multiple stat functions into one that returns a vector of results.

Combine multiple stat functions into one that returns a vector of results.
sourceraw docstring

stats-fn-mapclj

Map of stat keywords to their corresponding functions.

Map of stat keywords to their corresponding functions.
sourceraw docstring

stats-fnsclj

(stats-fns quantiles)

Build vector of stat functions including quantile functions for given quantiles.

Build vector of stat functions including quantile functions for given quantiles.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close