prettyRange: Pretty range

View source: R/prettyRange.R

prettyRangeR Documentation

Pretty range

Description

This function returns a pretty range of values for a given a vector of type numeric.

Usage

prettyRange(x)

Arguments

x

A vector of numerical values.

Details

This function intends to generate range with round values.

Value

A vector of two values specifying the pretty the range of values.

See Also

base::pretty()

Examples

# Example 1:
vec <- stats::runif(20)
range(vec)
prettyRange(vec)
# Example 2:
prettyRange(c(3.849,3.88245))

inSileco/graphicsutils documentation built on Sept. 12, 2022, 11:13 p.m.