reheadHTMLTable: Reformat HTML Table

Description Usage Arguments Value See Also Examples

View source: R/misc.R

Description

Convert a data frame to an HTML table object and reformat it.

Usage

1
2
3
reheadHTMLTable(dataset, heading, footRows = 0, align = c("left",
  rep("center", ncol - 1)), concatCol = NULL, caption = NULL,
  tableWidth = "100%")

Arguments

dataset

The dataset to draw table.

heading

The heading you want to input. '|' indicates colspan, '=' indicates rowspan.

footRows

The last several rows as <tfoot>.

align

Alignment of columns.

concatCol

Index of columns to concatenate, to make the table look hierachical.

caption

Table caption.

tableWidth

Width of the table.

Value

A table in HTML.

See Also

knitr::kable

Examples

1
2
3
4
5
6
7
## Not run: 
## A reformatted table with colspan/colrow=2
heading <- matrix(c("Sepal", NA, "Petal", NA, "Species", "Length", "Width",
                    "Length", "Width", NA), byrow=TRUE, nrow=2)
reheadHTMLTable(head(iris), heading)

## End(Not run)

madlogos/recharts2 documentation built on May 21, 2019, 11:03 a.m.