Synopsis
Reformats all numerical attributes according to the specified settings and change the attributes to nominal.
Description
This operator tries to parse numerical values and formats them in the specified number format. It also supports different kinds of numbers, including integers (123), fixed-point numbers (123.4), scientific notation (1.23E4), percentages (12%), and currency amounts ($123). The format type parameter specifies the basic format, in all cases but for "pattern" the specified locale will be used. In case of pattern the locale is ignored and the specified pattern is used instead.
Please note that this operator only works on numerical attributes and the result will be in any case a nominal attribute no matter if the resulting format would again be a parsable number.
In case of the pattern format type, a pattern parameter is used to define the format. If two different formats for positive and negative numbers should be used, those formats can be defined by a separating ';'. The pattern must have the following structure: pattern := subpattern{;subpattern} subpattern := {prefix}integer{.fraction}{suffix} prefix := any character combination including white space suffix := any character combination including white space integer := '#'* '0'* '0' fraction := '0'* '#'*
The following placeholders can be used within the pattern parameter: 0 a digit
- a digit, zero shows as absent
Input
- example set input: expects: ExampleSetMetaData: #examples: = 0; #attributes: 0
Output
- example set output:
- original:
Parameters
- attribute filter type: The condition specifies which attributes are selected or affected by this operator.
- attribute: The attribute which should be chosen.
- attributes: The attribute which should be chosen.
- regular expression: A regular expression for the names of the attributes which should be kept.
- use except expression: If enabled, an exception to the specified regular expression might be specified. Attributes of matching this will be filtered out, although matching the first expression.
- except regular expression: A regular expression for the names of the attributes which should be filtered out although matching the above regular expression.
- value type: The value type of the attributes.
- use value type exception: If enabled, an exception to the specified value type might be specified. Attributes of this type will be filtered out, although matching the first specified type.
- except value type: Except this value type.
- block type: The block type of the attributes.
- use block type exception: If enabled, an exception to the specified block type might be specified.
- except block type: Except this block type.
- numeric condition: Parameter string for the condition, e.g. '>= 5'
- invert selection: Indicates if only attributes should be accepted which would normally filtered.
- include special attributes: Indicate if this operator should also be applied on the special attributes. Otherwise they are always kept.
- format type: Number formatting will be performed according to the selected type.
- pattern: The format string, e.g. '0.###E0 m/s'.
- locale: The used locale for date texts, for example "Wed" (English) in contrast to "Mi" (German).
- use grouping: Indicates if a grouping character should be used for larger numbers (e.g. ',' for the US or '.' for Germany).