File tree 1 file changed +8
-2
lines changed
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -8062,15 +8062,21 @@ def first(self: FrameOrSeries, offset) -> FrameOrSeries:
8062
8062
8063
8063
def last (self : FrameOrSeries , offset ) -> FrameOrSeries :
8064
8064
"""
8065
- Method to subset final periods of time series data based on a date offset.
8065
+ Select final periods of time series data based on a date offset.
8066
+
8067
+ When having a DataFrame with dates as index, this function can
8068
+ select the last few rows based on a date offset.
8066
8069
8067
8070
Parameters
8068
8071
----------
8069
8072
offset : str, DateOffset, dateutil.relativedelta
8073
+ The offset length of the data that will be selected. For instance,
8074
+ '3D' will display all the rows having their index within the last 3 days.
8070
8075
8071
8076
Returns
8072
8077
-------
8073
- subset : same type as caller
8078
+ Series or DataFrame
8079
+ A subset of the caller.
8074
8080
8075
8081
Raises
8076
8082
------
You can’t perform that action at this time.
0 commit comments