Skip to content

LazyColumn.notnull

notnull

notnull() -> LazyColumn

Returns a boolean column indicating whether each value is non-null (NA).

Returns:

Name Type Description
LazyColumn LazyColumn

A new LazyColumn of boolean values, where True indicates a non-null value and False indicates a null value.

Examples:

print(df.head())
#    col1 my_column_to_test
# 0     1             None
# 1     2             10
# 2     3             None
# 3     4             15
# 4     5             None

df["my_column_to_test"].notnull()
# [False, True, False, True, False]