NormDiscrete

class NormDiscrete(val field: Field, val value: Any, val mapMissingTo: Option[Double]) extends FieldExpression

Encode string values into numeric values in order to perform mathematical computations. For example, regression and neural network models often split categorical and ordinal fields into multiple dummy fields. This kind of normalization is supported in PMML by the element NormDiscrete.

An element (f, v) defines that the unit has value 1.0 if the value of input field f is v, otherwise it is 0.

The set of NormDiscrete instances which refer to a certain input field define a fan-out function which maps a single input field to a set of normalized fields.

If the input value is missing and the attribute mapMissingTo is not specified then the result is a missing value as well. If the input value is missing and the attribute mapMissingTo is specified then the result is the value of the attribute mapMissingTo.

trait Evaluator
trait Serializable
class Object
trait Matchable
class Any

Value members

Concrete methods

override def eval(series: Series): Double
Definition Classes

Inherited methods

def categories: Array[Any]
Inherited from:
Expression
override def child: FieldRef
Definition Classes
Inherited from:
FieldExpression
final override def children: Array[Expression]
Definition Classes
Inherited from:
UnaryExpression
def deeval(value: Any): Any
Inherited from:
Expression
def eval(value: Any): Any
Inherited from:
Expression
Inherited from:
HasExtensions
override def getDataField: Option[Field]
Definition Classes
Inherited from:
FieldExpression
def hasExtensions: Boolean
Inherited from:
HasExtensions

Concrete fields

val mapMissingTo: Option[Double]
val value: Any