Skip to content

LazyColumn.notna

notna

notna() -> LazyColumn

A synonym for notnull(). 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.0
# 2     3               None
# 3     4               20.0
# 4     5               None

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