pyinterp.core.dateutils.isocalendar

pyinterp.core.dateutils.isocalendar(array: numpy.ndarray) numpy.typing.NDArray[pyinterp::dateutils::ISOCalendar]

Extract the ISO calendar from datetime64 values.

Computes the ISO year, week number, and weekday for each datetime64 value. Follows the ISO 8601 standard for week dates where week 1 contains the first Thursday of the year.

Parameters:

array – Numpy array of datetime64 to process.

Returns:

year, week, and weekday.

Return type:

Structured numpy array containing three fields

See also

datetime.date.isocalendar