Learn R Programming

RandomWalker (version 1.1.0)

confidence_interval: Confidence Interval

Description

Calculate the confidence interval

Usage

confidence_interval(.vector, .interval = 0.95)

Value

A named vector with the lower and upper bounds of the confidence interval

Arguments

.vector

A numeric vector of data points

.interval

A numeric value representing the confidence level (e.g., 0.95 for 95% confidence interval) The default is 0.95

Author

Steven P. Sanderson II, MPH

Details

This function calculates the confidence interval for a given vector and interval.

See Also

Other Utility Functions: convert_snake_to_title_case(), generate_caption(), get_attributes(), rand_walk_column_names(), rand_walk_helper(), running_quantile(), std_cum_max_augment(), std_cum_mean_augment(), std_cum_min_augment(), std_cum_prod_augment(), std_cum_sum_augment(), subset_walks()

Examples

Run this code
confidence_interval(rnorm(100), 0.95)

Run the code above in your browser using DataLab