Learn R Programming

hwriter (version 1.0)

hwrite: HTML writer

Description

Outputs an R object in HTML format.

Usage

hwrite(x, page=NULL, ...)

Arguments

x
an R object to output in HTML format. Objects of type character, vector, matrix and data.frame are currently supported.
page
an optional connection, a character string naming the file to write to or a page object returned by openPage.
...
optional arguments. See Details.

Value

  • A character vector containing the output HTML code.

Details

If x is a vector of only one element, it will be written by default as an HTML text element unless table is TRUE: in that case, it will be written as an HTML table containing an unique element.

If x is a vector of more than one element, a matrix or a data.frame, it will be written by default as an HTML table unless table is FALSE: in that case, it will be written as a vector or a matrix of HTML text elements.

Many optional arguments can be used to render an HTML object. See below for additional information. Many comprehensive examples can be found in the Examples section by typing example(hwrite).

See Also

openPage, closePage, hwriteImage, hmakeTag.

Examples

Run this code
hwriter:::showExample()

Run the code above in your browser using DataLab