EVOLUTION-MANAGER
Edit File: units_options.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: set one or more units global options</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_options {units}"><tr><td>units_options {units}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>set one or more units global options</h2> <h3>Description</h3> <p>set units global options, mostly related how units are printed and plotted </p> <h3>Usage</h3> <pre> units_options(..., sep, group, negative_power, parse, set_units_mode, auto_convert_names_to_symbols, simplify, allow_mixed, unitless_symbol, define_bel) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>...</code></td> <td> <p>named options (character) for which the value is queried</p> </td></tr> <tr valign="top"><td><code>sep</code></td> <td> <p>character length two; default <code>c("~", "~")</code>; space separator between variable and units, and space separator between two different units</p> </td></tr> <tr valign="top"><td><code>group</code></td> <td> <p>character length two; start and end group, may be two empty strings, a parenthesis pair, or square brackets; default: square brackets.</p> </td></tr> <tr valign="top"><td><code>negative_power</code></td> <td> <p>logical, default <code>FALSE</code>; should denominators have negative power, or follow a division symbol?</p> </td></tr> <tr valign="top"><td><code>parse</code></td> <td> <p>logical, default <code>TRUE</code>; should the units be made into an expression (so we get subscripts)? Setting to <code>FALSE</code> may be useful if <a href="../../base/html/parse.html">parse</a> fails, e.g. if the unit contains symbols that assume a particular encoding</p> </td></tr> <tr valign="top"><td><code>set_units_mode</code></td> <td> <p>character; either <code>"symbols"</code> or <code>"standard"</code>; see <a href="set_units.html">set_units</a>; default is <code>"symbols"</code></p> </td></tr> <tr valign="top"><td><code>auto_convert_names_to_symbols</code></td> <td> <p>logical, default <code>TRUE</code>: should names, such as <code>degree_C</code> be converted to their usual symbol?</p> </td></tr> <tr valign="top"><td><code>simplify</code></td> <td> <p>logical, default <code>NA</code>; simplify units in expressions?</p> </td></tr> <tr valign="top"><td><code>allow_mixed</code></td> <td> <p>logical; if <code>TRUE</code>, combining mixed units creates a <code>mixed_units</code> object, if <code>FALSE</code> it generates an error</p> </td></tr> <tr valign="top"><td><code>unitless_symbol</code></td> <td> <p>character; set the symbol to use for unitless (1) units</p> </td></tr> <tr valign="top"><td><code>define_bel</code></td> <td> <p>logical; if <code>TRUE</code>, define the unit <code>B</code> (i.e., the <em>bel</em>, widely used with the <em>deci-</em> prefix as <code>dB</code>, <em>decibel</em>) as an alias of <code>lg(re 1)</code>. <code>TRUE</code> by default, unless <code>B</code> is already defined in the existing XML database.</p> </td></tr> </table> <h3>Details</h3> <p>This sets or gets units options. Set them by using named arguments, get them by passing the option name. </p> <p>The default <code>NA</code> value for <code>simplify</code> means units are not simplified in <a href="set_units.html">set_units</a> or <a href="as_units.html">as_units</a>, but are simplified in arithmetical expressions. </p> <h3>Value</h3> <p>in case options are set, invisibly a named list with the option values that are being set; if an option is queried, the current option value. </p> <h3>Examples</h3> <pre> old = units_options(sep = c("~~~", "~"), group = c("", "")) # more space, parenthesis old ## set back to defaults: units_options(sep = c("~", "~"), group = c("[", "]"), negative_power = FALSE, parse = TRUE) units_options("group") </pre> <hr /><div style="text-align: center;">[Package <em>units</em> version 0.6-7 <a href="00Index.html">Index</a>]</div> </body></html>