Skip to content

Commit f749f92

Browse files
code sample for pandas-dev#40371
1 parent 1c98206 commit f749f92

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

bisect/40371.py

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# BUG: Change in behavior of replace with integer series and float to_replace
2+
# #40371
3+
4+
import numpy as np
5+
import pandas as pd
6+
7+
print(pd.__version__)
8+
9+
result = pd.Series([1]).replace(np.array([1.0]), [0])
10+
print(result)
11+
12+
expected = pd.Series([0])
13+
pd.testing.assert_series_equal(result, expected)

0 commit comments

Comments
 (0)