h.df: HTML Table of a data.frame

Description Usage Arguments Value Author(s)

Description

Transforms an R data.frame object into code for an HTML table.

Usage

1
2
h.df(a, rowcolors = FALSE, digits = 3, nsmall = 2, row.names = TRUE, 
	row.header = "")

Arguments

a

A data.frame or another object such as a matrix that can be cast as a data.frame.

rowcolors

Boolean value indicating whether alternate rows should be shaded light blue to facilitate reading. Default is FALSE.

digits

From the description for format: “how many significant digits are to be used for numeric and complex x.” The default is 3, but as the documentation for format indicates, “This is a suggestion: enough decimal places will be used so that the smallest (in magnitude) number has this many significant digits, and also to satisfy nsmall.”

nsmall

From the description for format: “the minimum number of digits to the right of the decimal point in formatting real/complex numbers in non-scientific formats. Allowed values are 0 <= nsmall <= 20.” The default is 2.

row.names

Boolean value indicating whether the data frame includes row names. Default is TRUE.

row.header

Label to be placed above the row names, such as “variables”. Default is “”.

Value

Returns a character vector of HTML code that begins with “<TABLE>” and ends with “/TABLE”. The elements of the HTML code are the elements of the data.frame, including the row and column names if they exist.

Author(s)

Bill Altermatt


DeducerRichOutput documentation built on May 2, 2019, 4:53 p.m.