Skip to contents

Functions like mtext or axis use the line argument to set the distance from plot. Sometimes it's useful to have the distance in user coordinates. lineToUser() does this nontrivial conversion.

Usage

lineToUser(line, side)

Arguments

line

the number of lines

side

the side of the plot

Value

the user coordinates for the given lines

Details

For the lineToUser function to work, there must be an open plot.

Examples


plot(1:10)

lineToUser(line=2, side=4)
#> [1] 11.07646