We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
softmax
1 parent 76e7228 commit cadd12fCopy full SHA for cadd12f
CHANGELOG.md
@@ -14,6 +14,7 @@
14
- [ENH] Add `names_expand` and `index_expand` parameters to `pivot_wider` for exposing missing categoricals. Issue #1108 @samukweku
15
- [ENH] Add fix for slicing error when selecting columns in `pivot_wider`. Issue #1134 @samukweku
16
- [ENH] `dropna` parameter added to `pivot_longer`. Issue #1132 @samukweku
17
+- [BUG] Force `math.softmax` returning `Series`. PR #1139 @Zeroto521
18
19
## [v0.23.1] - 2022-05-03
20
janitor/math.py
@@ -124,7 +124,8 @@ def softmax(s: pd.Series) -> pd.Series:
124
:param s: Input Series.
125
:return: Transformed Series.
126
"""
127
- return scipy_softmax(s)
+
128
+ return pd.Series(scipy_softmax(s), index=s.index, name=s.name)
129
130
131
@pf.register_series_method
0 commit comments