dataFrame.column.compare — notEmpty()

Description

The notEmpty() method of the compare object returns a boolean mask indicating which values are not empty.

Signature

dataFrame.column(columnName).compare.notEmpty()
Scope
column
Family
compare
Returns
mask

Argument

columnName (string)
The name of the column to compare values from.

Returns

mask ( boolean[] )
A boolean mask indicating the rows whose values are not empty.
  • Not empty value: 1
  • Otherwise: 0

Example

// get the mask of rows where the column 'name' is not empty
var mask = df.column('name').compare.notEmpty();

// set mask to dataFrame
df.column('empty').set(mask);