diff --git a/zipline/data/us_equity_pricing.py b/zipline/data/us_equity_pricing.py index 0cfdd700a5..b21210e8a1 100644 --- a/zipline/data/us_equity_pricing.py +++ b/zipline/data/us_equity_pricing.py @@ -160,7 +160,7 @@ def winsorise_uint32(df, invalid_data_behavior, column, *columns): stacklevel=3, # one extra frame for `expect_element` ) - df[mask] = 0 + df = df.where(~mask, other=0) return df