Table: Pretty Print Data

Description Usage Arguments Value Examples

Description

Table formats and prints data. Rows and columns are truncated to fit on screen and columns are aligned.

Usage

1
2
Table(x, n = 30, align = "auto", digits = 3, trunc = "long",
  rows = TRUE, sub = NULL, start = 1, sep = NULL)

Arguments

x

object to be printed

n

maximum number of rows to print. If 'ht', head and tail are printed

align

vector of characters describing column alignment. Accepts 'l' for left, 'r' for right, 'c' for center, 'd' for aligning on decimal place, 't' for left alignment and truncation, 'm' for truncating to the shortest character. 'auto' aligns center for characters and on the decimal place for numeric values.

digits

number of digits to which numeric values are rounded

trunc

character or numeric value. Character values of 'long' or 'col' are accepted. 'long' truncates the widest column if necessary, 'col' removes necessary columns. Numeric values specify which columns to truncate.

rows

logical. Are row numbers printed?

sub

vector to be printed under column names. If 'type', the type of each column is printed

start

starting row number of the data to print

sep

defaults to NULL. Row number after which to draw a line

Value

prints truncated table of data

Examples

1
2
3
4
5
GDP <- fred('GDP')
Table(GDP)

data(pwt9)
Table(pwt9, sub = 'type', trunc = 'col')

cmann3/econ311 documentation built on May 31, 2019, 1:14 p.m.