Skip to content

Commit 9ac81f0

Browse files
committed
Add np.array for read-only ndarray
1 parent eed6121 commit 9ac81f0

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pandas/core/generic.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9713,6 +9713,8 @@ def _where(
97139713
else:
97149714
if not hasattr(cond, "shape"):
97159715
cond = np.asanyarray(cond)
9716+
else:
9717+
cond = np.array(cond)
97169718
cond[isna(cond)] = True
97179719
if cond.shape != self.shape:
97189720
raise ValueError("Array conditional must be same shape as self")

0 commit comments

Comments
 (0)