Module: tf_quant_finance.datetime.utils

Contents

Last updated: 2023-03-16.

Module: tf_quant_finance.datetime.utils#

View source

Utilities for working with dates.

Functions#

days_in_leap_and_nonleap_years_between(...): Calculates number of days that fall on leap and non-leap years.

days_in_leap_years_between(...): Calculates number of days between two dates that fall on leap years.

is_leap_year(...): Calculates whether years are leap years.

leap_days_between(...): Calculates number of leap days (29 Feb) between two dates.

ordinal_to_year_month_day(...): Calculates years, months and dates Tensor given ordinals Tensor.

year_month_day_to_ordinal(...): Calculates ordinals Tensor given years, months and dates.