The following node is available in the Open Source KNIME predictive analytics and data mining platform version 2.7.1. Discover over 1000 other nodes, as well as enterprise functionality at
http://knime.com.
Round Double
Rounds double values to the specified decimal place or significant
figures, applying the specified rounding method. The columns
containing the double values can be specified. The rounded values
can be appended as additional columns, or the old values are
replaced by the rounded values. If rounded values are appended as
additional columns, a column suffix for the columns to append needs
to be specified.
To round the values seven different rounding modes are available:
UP, DOWN, CEILING, FLOOR, HALF_UP, HALF_DOWN, HALF_EVEN. For the
detailed description of each rounding mode please see the
Java documentation.
Dialog Options
- Column selection
-
The columns containing double values to round.
- Append rounded values as additional columns
-
If checked the rounded values will be appended as additional
columns. For each selected column one additional column containing
the rounded values will be appended. If not checked, the input
double values will be replaced by the rounded values.
- Column suffix
-
If "Append rounded values as additional columns" is checked a
column suffix must be specified. The names of the new columns
are those of the original columns with the specified suffix
appended.
- Format as string
-
If checked, the rounded values in the output table will be
represented as strings. The rounded double values may have another
scale as specified by the setting "Precision", since e.g.
trailing zeros will be removed. The rounded values represented as
strings will always have the exact scale which is specified.
- Precision
-
The scale of the double values to round to. If the scale is reduced
the specified rounding mode is applied.
- Precision mode
-
The type of precision to which the values are rounded. Decimal
places, the default option rounds to the specified decimal places,
whereas significant figures rounds to significant figures or
numbers.
- Rounding mode
-
The rounding mode which is applied when double values are rounded.
The rounding mode specifies the rounding behavior. Seven different
rounding modes are available:
- UP: Rounding mode to round away from zero.
- DOWN: Rounding mode to round towards zero.
- CEILING: Rounding mode to round towards positive infinity.
- FLOOR: Rounding mode to round towards negative infinity.
- HALF_UP: Rounding mode to round towards "nearest neighbor" unless both neighbors are equidistant, in which case round up.
- HALF_DOWN: Rounding mode to round towards "nearest neighbor" unless both neighbors are equidistant, in which case round down.
- HALF_EVEN: Rounding mode to round towards the "nearest neighbor" unless both neighbors are equidistant, in which case, round towards the even neighbor.
For a detailed description of each rounding mode please see the
Java documentation.
Ports
Input Ports
0 |
The input table containing double values to convert.
|
Output Ports
0 |
The output table containing the rounded double values.
|
This node is contained in KNIME Base Nodes
provided by KNIME GmbH, Konstanz, Germany.