boot.mean

0th

Percentile

Bootstrapped Mean

Function to obtain a sampling distribution of means by bootstrapping.

Usage
boot.mean(x, B, n = length(x))
Arguments
x

original sample, given as a numeric or logical object, to be used to generate bootstrapped samples.

B

number of bootstrapped samples to be generated by randomly sampling with replacement.

n

size of each bootstrapped sample. Default setting is the size of the original sample.

Value

A list with components:

Replications

number of bootstrapped means computed.

mean

mean of bootstrapped means.

se

standard error, estimated as the standard deviation of bootstrapped means.

bootstrap.samples

means of bootstrapped samples.

See Also

set.seed

Aliases
  • boot.mean
Examples
# NOT RUN {
# using simple vector
a = 1:10
set.seed(1234)
boot.mean(a, B = 500)

# using variable from data frame
set.seed(1234)
boot.mean(Framingham$AGE3, B = 1000)
# }
Documentation reproduced from package sur, version 1.0.0, License: GPL (>= 2)

Community examples

Looks like there are no examples yet.