html
is a generic function, for which only two methods are currently
implemented,
html.latex
and a rudimentary
html.data.frame
. The former uses the
HeVeA
LaTeX to HTML
translator by Maranget to create an HTML file from a LaTeX file like
the one produced by
latex
. The resulting HTML file may be
displayed using a
show
or a
print
method. The browser
specified in
options(browser=)
for R (
help.browser
for
S-Plus) is launched to display the HTML file.
html.default
just
runs
html.data.frame
.
html(object, ...) ## S3 method for class 'latex': html(object, ...) ## S3 method for class 'data.frame': html(object, file=paste(first.word(deparse(substitute(object))),'html',sep='.'), append=FALSE, link=NULL, linkCol=1, linkType=c('href','name'), ...) ## Default S3 method: html(object, file=paste(first.word(deparse(substitute(object))),'html',sep='.'), append=FALSE, link=NULL, linkCol=1, linkType=c('href','name'), ...) ## S3 method for class 'html': print(x, ...) ## S3 method for class 'html': show(object)
latex
. For
show
is an object created by
html
. For the generic
html
is any object for which an
html
method exists.
object.html
where
object
is the first word in
the name of the argument for
object
.
TRUE
to append to an existing file
link
is omitted or for elements of
link
that are
""
.
object
to which hyperlinks are
attached. Defaults to first column.
"href"
format.df
html
Frank E. Harrell, Jr.
Department of Biostatistics,
Vanderbilt University,
mailto:f.harrell@vanderbilt.edu
Maranget, Luc. HeVeA: a LaTeX to HTML translater. URL: http://para.inria.fr/~maranget/hevea/
## Not run: x <- matrix(1:6, nrow=2, dimnames=list(c('a','b'),c('c','d','e'))) w <- latex(x) h <- html(w) # run HeVeA to convert .tex to .html h <- html(x) # convert x directly to html options(browser='konqueror') # use help.browser for S-Plus h # launch html browser by running print.html w <- html(x, link=c('','B')) # hyperlink first row first col to B ## End(Not run)