partyprint {pinktoe}R Documentation

Function suitable for use as the stateprintfn argument for pinktoe for the EDM example

Description

In response to a variable (from the var component of the frame component of the relevant tree or rpart object this function issues perl commands which call functions in the partylib object (which can be supplied as a requirelib object for pinktoe

Usage

partyprint(yval, file = "", append = FALSE)

Arguments

yval One of "Lab", "Con", "LDem", "UU", "PC", "SNP": parties in the British Political system
file perl file to write the output code to
append Should be TRUE

Details

This file should produce perl code to do something when a yval is produced. A yval is one of the elements of the var column in the frame dataframe of a tree or rpart object. In this case the elements are all political parties indicated by the possibilities described in the yval argument to this function. Here perl code is generated which calls a function, one for each political party. See example below.

Value

Nothing.

Author(s)

Guy P Nason

References

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

See Also

pinktoe

Examples

partyprint("Lab", file="", append=TRUE)
# &labour;
#
#
# So the perl function labour gets called.


[Package pinktoe version 2.0 Index]