Learn R Programming

MultBiplotR (version 23.11.0)

PrettyTicks: Calculates loose axis ticks and labels using nice numbers

Description

Calculates axis ticks and labels using nice numbers

Usage

PrettyTicks(min = -3, max = 3, ntick = 5)

Value

A list with the following fields

ticks

Ticks for the axis

labels

The corresponding labels

Arguments

min

Minimum value on the axis

max

maximum value on the axis.

ntick

Approximated number of desired ticks

Author

Jose Luis Vicente Villardon

Details

Calculates axis ticks and labels using nice numbers. The resulting labels are known as loose labels.

References

Heckbert, P. S. (1990). Nice numbers for graph labels. In Graphics Gems (pp. 61-63). Academic Press Professional, Inc..

See Also

NiceNumber

Examples

Run this code
PrettyTicks(-4, 4, 5)

Run the code above in your browser using DataLab