pmml (version 1.5.1)

makeOutputNodes: Add Output nodes to a PMML object.

Description

Add Output nodes to a PMML object.

Usage

makeOutputNodes(name = "OutputField", attributes = NULL, expression = NULL, namespace = "4_2")

Arguments

name
The name of the element to be created
attributes
The node attributes to be added
expression
Post-processing information to be included in the element. This expression will be processed by the functionToPMML function
namespace
The namespace of the PMML model

Value

List of nodes

Details

This function will create a list of nodes with names 'name', attributes 'attributes' and child elements 'expression'. 'expression' is a string converted to XML similar to th functionToPMML function. Meant to create OutputField elements, 'expressions' allows one to include post-processing transformations to a model. To create multiple such nodes, all the parameters must be given as lists of equal length.

Examples

Run this code
# make 2 nodes, one with attributes 
TwoNodes <- makeOutputNodes(name=list("OutputField","OutputField"),
             attributes=list(list(name="dbl",optype="continuous"),NULL),
             expression=list("ln(x)","ln(x/(1-x))"))

Run the code above in your browser using DataCamp Workspace