Skip to content

Commit 816db57

Browse files
committed
Doc fixups
1 parent 5e9de2d commit 816db57

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

doc/source/user_guide/basics.rst

+3
Original file line numberDiff line numberDiff line change
@@ -1045,6 +1045,9 @@ not noted for a particular column will be ``NaN``:
10451045
Mixed dtypes
10461046
++++++++++++
10471047

1048+
.. deprecated:: 1.4.0
1049+
Attempting to determine which columns cannot be aggregated and silently dropping them from the results is deprecated and will be removed in a future version. If any porition of the columns or operations provided fail, the call to ``.agg`` will raise.
1050+
10481051
When presented with mixed dtypes that cannot aggregate, ``.agg`` will only take the valid
10491052
aggregations. This is similar to how ``.groupby.agg`` works.
10501053

doc/source/user_guide/groupby.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -578,7 +578,7 @@ column, which produces an aggregated result with a hierarchical index:
578578

579579
.. ipython:: python
580580
581-
grouped.agg([np.sum, np.mean, np.std])
581+
grouped[["C", "D"]].agg([np.sum, np.mean, np.std])
582582
583583
584584
The resulting aggregations are named for the functions themselves. If you
@@ -597,7 +597,7 @@ For a grouped ``DataFrame``, you can rename in a similar manner:
597597
.. ipython:: python
598598
599599
(
600-
grouped.agg([np.sum, np.mean, np.std]).rename(
600+
grouped[["C", "D"]].agg([np.sum, np.mean, np.std]).rename(
601601
columns={"sum": "foo", "mean": "bar", "std": "baz"}
602602
)
603603
)

doc/source/whatsnew/v0.20.0.rst

+1
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ aggregations. This is similar to how groupby ``.agg()`` works. (:issue:`15015`)
105105
df.dtypes
106106
107107
.. ipython:: python
108+
:okwarning:
108109
109110
df.agg(['min', 'sum'])
110111

0 commit comments

Comments
 (0)