Skip to content

LazyColumn.dt.is_month_end

is_month_end property

is_month_end: LazyColumn

Checks if each datetime value is the end of the month.

Returns:

Name Type Description
LazyColumn LazyColumn

A boolean LazyColumn, where True indicates the value is the last day of its month.

Examples:

print(df.head())
#              my_datetime_column
# 0  2023-01-31 23:59:59  # end of January
# 1  2023-02-28 12:34:56
# 2  2023-02-15 00:00:00
# 3  2023-02-28 23:59:59  # end of February (non leap year)

df["my_datetime_column"].dt.is_month_end
# [True, True, False, True, ...]