lim: Axis Limits

View source: R/lim.R

limR Documentation

Axis Limits

Description

Compute reasonable axis limits for plotting non-negative numbers.

Usage

lim(x, mult = 1.1)

Arguments

x

a vector of data values.

mult

a number to multiply with the highest data value.

Value

A vector of length two, which can be used as axis limits.

Note

The lower limit is set to 0, and the upper limit is determined by the highest data value, times a multiplier.

See Also

TAF-package gives an overview of the package.

Examples

plot(precip)
plot(precip, ylim=lim(precip))
plot(precip, ylim=lim(precip), yaxs="i")


TAF documentation built on March 31, 2023, 6:51 p.m.