ggpmisc (version 0.3.2)

symmetric_limits: Expand limits to be symetric

Description

A simple function to expand scale limits to be symetric around zero. Can be passed as argument to parameter limits of continuous scales from packages 'ggplot2' or 'scales'.

Usage

symmetric_limits(x)

Arguments

x

numeric The automatic limits

Value

A numeric vector of length two with the new limits.

Examples

Run this code
# NOT RUN {
symmetric_limits(c(-1, 1.8))

# }

Run the code above in your browser using DataLab