DropNA  type: dropna#

class lumen.transforms.base.DropNA(*, axis, how, subset, thresh, controls, name)#

DropNA drops rows with any missing values.

df.dropna(axis=<axis>, how=<how>, thresh=<thresh>, subset=<subset>)


Parameters#

axis

type: int | str
default: 0
The axis to rename. 0 or ‘index’, 1 or ‘columns’

how

type: Any
default: 'any'
Possible values: 'any' | 'all'
Determine if row or column is removed from DataFrame, when we haveat least one NA or all NA.

subset

type: Any
default: None
Possible values: ``
Labels along other axis to consider, e.g. if you are dropping rowsthese would be a list of columns to include.

thresh

type: int
default: None
bounds: None
Require that many non-NA values.


Methods#

DropNA.apply(table: DataFrame) DataFrame#

Given a table transform it in some way and return it.

Parameters:

table (DataFrame) – The queried table as a DataFrame.

Returns:

A DataFrame containing the transformed data.

Return type:

DataFrame

DropNA.to_spec(context: Dict[str, Any] | None = None) Dict[str, Any]#

Exports the full specification to reconstruct this component.

Return type:

Resolved and instantiated Component object