Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

xaxsd

Par args xaxs and yaxs option d


Description

Implements par('xaxs') and par('yaxs') option 'd'.

Usage

xaxsd(usr = par()$usr[1:2])

yaxsd(usr = par()$usr[3:4])

Arguments

usr

a length-2 vector defining the length of the x-axis or y-axis.

Details

Implements par('xaxs') and par('yaxs') option 'd', i.e. uses previous axis scales in a new plot.

Value

By default returns xlim/ylim args to match current setting of par()$usr, i.e. previous plot scales. Specifying usr gives scales with the usr args at the extremes. If par('xlog') or par('ylog') are set the returned limits are antilogged (to base 10).

Author(s)

Examples

## generate and plot 100 data points
x <- rnorm(100)
y <- rnorm(100)
plot(x, y, pch=19)

## generate and plot 10 more
## constraining axis scales to be as before
x <- rnorm(10)
y <- rnorm(10)
plot(x, y, pch=19, xlim=xaxsd(), ylim=yaxsd())

## force axis extremes to be -3 and 3
plot(x, y, pch=19, xlim=xaxsd(c(-3,3)), ylim=yaxsd(c(-3,3)))

sitar

Super Imposition by Translation and Rotation Growth Curve Analysis

v1.2.0
GPL (>= 2)
Authors
Tim Cole [aut, cre] (<https://orcid.org/0000-0001-5711-8200>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.