Skip to content

Commit 9001cb2

Browse files
DOC: fix ES01 for pandas.DataFrame.shape (pandas-dev#60888)
1 parent deafcf7 commit 9001cb2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pandas/core/frame.py

+4
Original file line numberDiff line numberDiff line change
@@ -1021,6 +1021,10 @@ def shape(self) -> tuple[int, int]:
10211021
"""
10221022
Return a tuple representing the dimensionality of the DataFrame.
10231023
1024+
Unlike the `len()` method, which only returns the number of rows, `shape`
1025+
provides both row and column counts, making it a more informative method for
1026+
understanding dataset size.
1027+
10241028
See Also
10251029
--------
10261030
numpy.ndarray.shape : Tuple of array dimensions.

0 commit comments

Comments
 (0)