EVOLUTION-MANAGER
Edit File: tables.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: Display 'data.table' metadata</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 tables {data.table}"><tr><td>tables {data.table}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>Display 'data.table' metadata </h2> <h3>Description</h3> <p>Convenience function for concisely summarizing some metadata of all <code>data.table</code>s in memory (or an optionally specified environment). </p> <h3>Usage</h3> <pre> tables(mb=TRUE, order.col="NAME", width=80, env=parent.frame(), silent=FALSE, index=FALSE) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>mb</code></td> <td> <p><code>logical</code>; <code>TRUE</code> adds the rough size of each <code>data.table</code> in megabytes to the output under column <code>MB</code>. </p> </td></tr> <tr valign="top"><td><code>order.col</code></td> <td> <p> Column name (<code>character</code>) by which to sort the output. </p> </td></tr> <tr valign="top"><td><code>width</code></td> <td> <p><code>integer</code>; number of characters beyond which the output for each of the columns <code>COLS</code>, <code>KEY</code>, and <code>INDICES</code> are truncated. </p> </td></tr> <tr valign="top"><td><code>env</code></td> <td> <p> An <code>environment</code>, typically the <code>.GlobalEnv</code> by default, see Details. </p> </td></tr> <tr valign="top"><td><code>silent</code></td> <td> <p><code>logical</code>; should the output be printed? </p> </td></tr> <tr valign="top"><td><code>index</code></td> <td> <p><code>logical</code>; if <code>TRUE</code>, the column <code>INDICES</code> is added to indicate the indices assorted with each object, see <code><a href="setkey.html">indices</a></code>. </p> </td></tr> </table> <h3>Details</h3> <p>Usually <code>tables()</code> is executed at the prompt, where <code>parent.frame()</code> returns <code>.GlobalEnv</code>. <code>tables()</code> may also be useful inside functions where <code>parent.frame()</code> is the local scope of the function; in such a scenario, simply set it to <code>.GlobalEnv</code> to get the same behaviour as at prompt. </p> <p>Note that on older versions of <span style="font-family: Courier New, Courier; color: #666666;"><b>R</b></span>, <code>object.size</code> may be slow, so setting <code>mb=FALSE</code> may speed up execution of <code>tables</code> significantly. </p> <p>Setting <code>silent=TRUE</code> prints nothing; the metadata are returned as a <code>data.table</code>, invisibly, whether silent is <code>TRUE</code> or <code>FALSE</code>. </p> <h3>Value</h3> <p>A <code>data.table</code> containing the information printed. </p> <h3>See Also</h3> <p><code><a href="data.table.html">data.table</a></code>, <code><a href="setkey.html">setkey</a></code>, <code><a href="../../base/html/ls.html">ls</a></code>, <code><a href="../../base/html/ls.html">objects</a></code>, <code><a href="../../utils/html/object.size.html">object.size</a></code> </p> <h3>Examples</h3> <pre> DT = data.table(A=1:10, B=letters[1:10]) DT2 = data.table(A=1:10000, ColB=10000:1) setkey(DT,B) tables() </pre> <hr /><div style="text-align: center;">[Package <em>data.table</em> version 1.14.4 <a href="00Index.html">Index</a>]</div> </body></html>