File tree 1 file changed +6
-0
lines changed
1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -441,8 +441,14 @@ Enhancements
441
441
- ``pandas.tseries.holiday`` has added support for additional holidays and ways to observe holidays (:issue:`7070`)
442
442
- ``pandas.tseries.holiday.Holiday`` now supports a list of offsets in Python3 (:issue:`7070`)
443
443
- ``pandas.tseries.holiday.Holiday`` now supports a days_of_week parameter (:issue:`7070`)
444
+ - ``GroupBy.nth()`` now supports selecting multiple nth values (:issue:`7910`)
444
445
446
+ .. ipython:: python
445
447
448
+ business_dates = date_range(start='4/1/2014', end='6/30/2014', freq='B')
449
+ df = DataFrame(1, index=business_dates, columns=['a', 'b'])
450
+ # get the first, 4th, and last date index for each month
451
+ df.groupby((df.index.year, df.index.month)).nth([0, 3, -1])
446
452
447
453
- ``Period`` and ``PeriodIndex`` supports addition/subtraction with ``timedelta``-likes (:issue:`7966`)
448
454
You can’t perform that action at this time.
0 commit comments