vec_range: Range of values for vector classes.

Description Usage Arguments Details Value Examples

View source: R/range.R

Description

Mimicking range, but doesn't necessarily return the range as a length 2 vector. Also gives the option to take the range along an "x"- or "y"-direction with the aes argument.

Usage

1
2
3
4
vec_range(...)

## Default S3 method:
vec_range(..., na.rm = FALSE, finite = FALSE, aes = NULL)

Arguments

...

Objects for which the range should be returned.

na.rm

A logical of length 1, indicating if NA's should be omitted

finite

A logical of length 1, indicating if all non-finite elements should be omitted

aes

An aesthetic name

Details

Written as a seperate function from range, to distinguish that the expected return value will not always be of length 2.

Value

A vector containing the minimum and maximum of the given arguments.

Examples

1
vec_range(1:10)

teunbrand/ggvctrcoords documentation built on Jan. 12, 2020, 6:25 p.m.