dataFrame.column.num — floor()

Description

The floor() method of the num object returns the values of the selected column rounded down to the specified number of decimal places.

Signature

dataFrame.column(columnName).num.floor(decimals)
Scope
dataFrame
Family
num
Returns
array

Argument

columnName (string)
The name of the column containing the values to round.
decimals (number)
The number of decimal places to keep.

Returns

mask ( number[] )
An array containing the rounded values.

Example

// round down values from a column of the dataFrame
var mask = dataFrame.column('values').num.ceil(2);

// add values to the dataFrame
dataFrame.column('newValues').set(mask);