calculate_range: Function to summaries a numeric vector by calculating and...

View source: R/calculate_range.R

calculate_rangeR Documentation

Function to summaries a numeric vector by calculating and minimum, maximum, range, and other summary statistics.

Description

Function to summaries a numeric vector by calculating and minimum, maximum, range, and other summary statistics.

Usage

calculate_range(x, inf_to_na = FALSE)

Arguments

x

Numeric vector.

inf_to_na

Should any Inf or -Inf values be transformed to NA? Inf values occur if there are no non-missing elements in the vector and can cause issues plotting.

Value

A tibble with one row.

Author(s)

Stuart K. Grange.

See Also

calculate_ci, calculate_quantiles

Examples


# Calculate a few summaries with this vector
x <- c(44617L, 7066L, 17594L, 2726L, 1178L, 18898L, 5033L, 37151L,  4514L, 4000L)

# Calculate the summaries
calculate_range(x)


skgrange/threadr documentation built on April 15, 2024, 9:35 p.m.