monthly_mean#
- monthly_mean(data, tstart, tend, time_axis=0)[source]#
Compute monthly means for daily, contiguous data in [tstart, tend] (inclusive).
- Parameters:
data (np.ndarray) – Input array. One axis is time (daily).
tstart (datetime.datetime) – Inclusive range of the data.
tend (datetime.datetime) – Inclusive range of the data.
time_axis (int) – Axis that represents time in data.
- Returns:
monthly (np.ndarray) – Monthly means with time axis replaced by number of months.
month_labels (np.ndarray of datetime64[M]) – Month labels for each output slice.