File tree 2 files changed +26
-4
lines changed
2 files changed +26
-4
lines changed Original file line number Diff line number Diff line change @@ -99,7 +99,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
99
99
pandas.api.extensions.ExtensionDtype \
100
100
pandas.api.extensions.ExtensionArray \
101
101
pandas.arrays.NumpyExtensionArray \
102
- pandas.api.extensions.ExtensionArray._accumulate \
103
102
pandas.api.extensions.ExtensionArray._concat_same_type \
104
103
pandas.api.extensions.ExtensionArray._formatter \
105
104
pandas.api.extensions.ExtensionArray._from_factorized \
@@ -110,9 +109,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
110
109
pandas.api.extensions.ExtensionArray._values_for_factorize \
111
110
pandas.api.extensions.ExtensionArray.interpolate \
112
111
pandas.api.extensions.ExtensionArray.ravel \
113
- pandas.api.extensions.ExtensionArray.ndim \
114
- pandas.api.extensions.ExtensionArray.shape \
115
- pandas.api.extensions.ExtensionArray.tolist \
116
112
pandas.DataFrame.__dataframe__
117
113
RET=$(( $RET + $? )) ; echo $MSG " DONE"
118
114
Original file line number Diff line number Diff line change @@ -520,6 +520,12 @@ def dtype(self) -> ExtensionDtype:
520
520
def shape (self ) -> Shape :
521
521
"""
522
522
Return a tuple of the array dimensions.
523
+
524
+ Examples
525
+ --------
526
+ >>> arr = pd.array([1, 2, 3])
527
+ >>> arr.shape
528
+ (3,)
523
529
"""
524
530
return (len (self ),)
525
531
@@ -536,6 +542,12 @@ def size(self) -> int:
536
542
def ndim (self ) -> int :
537
543
"""
538
544
Extension Arrays are only allowed to be 1-dimensional.
545
+
546
+ Examples
547
+ --------
548
+ >>> arr = pd.array([1, 2, 3])
549
+ >>> arr.ndim
550
+ 1
539
551
"""
540
552
return 1
541
553
@@ -1599,6 +1611,14 @@ def _accumulate(
1599
1611
Raises
1600
1612
------
1601
1613
NotImplementedError : subclass does not define accumulations
1614
+
1615
+ Examples
1616
+ --------
1617
+ >>> arr = pd.array([1, 2, 3])
1618
+ >>> arr._accumulate(name='cumsum')
1619
+ <IntegerArray>
1620
+ [1, 3, 6]
1621
+ Length: 3, dtype: Int64
1602
1622
"""
1603
1623
raise NotImplementedError (f"cannot perform { name } with type { self .dtype } " )
1604
1624
@@ -1694,6 +1714,12 @@ def tolist(self) -> list:
1694
1714
Returns
1695
1715
-------
1696
1716
list
1717
+
1718
+ Examples
1719
+ --------
1720
+ >>> arr = pd.array([1, 2, 3])
1721
+ >>> arr.tolist()
1722
+ [1, 2, 3]
1697
1723
"""
1698
1724
if self .ndim > 1 :
1699
1725
return [x .tolist () for x in self ]
You can’t perform that action at this time.
0 commit comments