diff --git a/pandas/core/generic.py b/pandas/core/generic.py index d5bdeb7fe1a4d..a6b7a3d6cd02a 100644 --- a/pandas/core/generic.py +++ b/pandas/core/generic.py @@ -3660,7 +3660,11 @@ def head(self, n=5): def tail(self, n=5): """ - Return the last n rows. + Return the last `n` rows. + + This function returns last `n` rows from the object based on + position. It is useful for quickly verifying data, for example, + after sorting or appending rows. Parameters ---------- @@ -3702,7 +3706,7 @@ def tail(self, n=5): 7 whale 8 zebra - Viewing the last n lines (three in this case) + Viewing the last `n` lines (three in this case) >>> df.tail(3) animal