writehtml {pinktoe}R Documentation

Write the HTML file for an EDM decision and return the names of the called perl files so that they can be constructed.

Description

Part of the pinktoe suite this function writes the HTML files that a web server will serve. The content of these HTML files will be some explanatory text (generated by edmtextfn, edmtittext), with a check box that will record the answer to the question specified in the HTML file. These HTML files will be able to call perl files and their names are constructed by this function and returned (and later used by writeperl).

Usage

writehtml(edmlabel, uniqedmlab, edmtextfn, edmtittext, cgibindir, localdir, commonhtml, numvar, numstring, treeobj)

Arguments

edmlabel The variable name (from the var field of the original tree) for this HTML file/question.
uniqedmlab HTML file is associated with a node which is a given split on a variable: a unique filename for each node should be supplied (genedmhtml generates this by combining the variable name with the node number).
edmtextfn A function that can print out explanatory text given a variable name (see web help page and \end{displaymath}.text example.
edmtittext Prints out a title string given a variable name
cgibindir A character string containing the directory where the perl files generated by pinktoe (with the extension .pl) will be stored. (This should be the directory part of the URL of the cgi-bin directory).
localdir A local location to store both the HTML and perl files immediately after they are generated
commonhtml A user-supplied function that prints out some HTML code. This is appended to every HTML web page.
numvar Logical variable which is TRUE is the variable for this HTML is numeric, FALSE if it is a factor.
numstring The S character string which describes the split (either factor or numeric) for this variable. Basically one of the cells in the dataframe returned by splits.rpart
treeobj The rpart (or tree) object that this whole process is concerned with

Details

Writes the HTML files

Value

The HTML file here creates a checkbox. The result of which causes a call to a perl function. The HTML file here creates the perl file name and passes it back to its calling function (genedmhtml) which then creates the perl function and supplies it with the file name. This function returns the perl filename.

Note

Not intended for general user use

Author(s)

Guy P Nason

References

http://www.stats.bris.ac.uk/~magpn/Research/Pinktoe/Welcome.html

See Also

pinktoe

Examples

#
#Not intended for general user use
#

[Package pinktoe version 2.0 Index]