EVOLUTION-MANAGER
Edit File: units.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: Graphical Units</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" type="text/css" href="R.css" /> </head><body> <table width="100%" summary="page for units {graphics}"><tr><td>units {graphics}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>Graphical Units</h2> <h3>Description</h3> <p><code>xinch</code> and <code>yinch</code> convert the specified number of inches given as their arguments into the correct units for plotting with graphics functions. Usually, this only makes sense when normal coordinates are used, i.e., <em>no</em> <code>log</code> scale (see the <code>log</code> argument to <code><a href="par.html">par</a></code>). </p> <p><code>xyinch</code> does the same for a pair of numbers <code>xy</code>, simultaneously. </p> <h3>Usage</h3> <pre> xinch(x = 1, warn.log = TRUE) yinch(y = 1, warn.log = TRUE) xyinch(xy = 1, warn.log = TRUE) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>x, y</code></td> <td> <p>numeric vector</p> </td></tr> <tr valign="top"><td><code>xy</code></td> <td> <p>numeric of length 1 or 2.</p> </td></tr> <tr valign="top"><td><code>warn.log</code></td> <td> <p>logical; if <code>TRUE</code>, a warning is printed in case of active log scale.</p> </td></tr> </table> <h3>Examples</h3> <pre> all(c(xinch(), yinch()) == xyinch()) # TRUE xyinch() xyinch #- to see that is really delta{"usr"} / "pin" ## plot labels offset 0.12 inches to the right ## of plotted symbols in a plot with(mtcars, { plot(mpg, disp, pch = 19, main = "Motor Trend Cars") text(mpg + xinch(0.12), disp, row.names(mtcars), adj = 0, cex = .7, col = "blue") }) </pre> <hr /><div style="text-align: center;">[Package <em>graphics</em> version 3.6.0 <a href="00Index.html">Index</a>]</div> </body></html>