Counts the number of valid days between begindates and enddates, not including the day of enddates.
If enddates specifies a date value that is earlier than the corresponding begindates date value, the count will be negative.
New in version 1.7.0.
Parameters : | begindates : array_like of datetime64[D]
enddates : array_like of datetime64[D]
weekmask : str or array_like of bool, optional
holidays : array_like of datetime64[D], optional
busdaycal : busdaycalendar, optional
out : array of int, optional
|
---|---|
Returns : | out : array of int
|
See also
Examples
>>> # Number of weekdays in January 2011
... np.busday_count('2011-01', '2011-02')
21
>>> # Number of weekdays in 2011
... np.busday_count('2011', '2012')
260
>>> # Number of Saturdays in 2011
... np.busday_count('2011', '2012', weekmask='Sat')
53