You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently in partial dependence, if you are calculating the partial dependence for an Integer logical type column, when we get the grid values with _grid_from_X, if there are more unique values in the integer column than the grid resolution, we calculate grid values to use with mscipy.sttats.mquantiles. This can introduce fractional values. With the Integer logical type, we can set a column with fractional values to the int64 dtype and pandas will truncate the value. Our IntegerNullable logical type, which uses Int64 dtype, on the other hand, does not allow that. Because of this, we’ll need to make some change to allow partial dependence on IntegerNullable columns (I don’t view this as an integer nullable incompatibility, since I think pandas is probably right to not just silently truncate your data).
Code Sample, a copy-pastable example to reproduce your bug.
We will need to handle the IntegerNullable case, and while we're doing that, we should make the handling of fractional values for Integer columns explicit by rounding instead of letting the values get truncated.
The text was updated successfully, but these errors were encountered:
Currently in partial dependence, if you are calculating the partial dependence for an Integer logical type column, when we get the grid values with _grid_from_X, if there are more unique values in the integer column than the grid resolution, we calculate grid values to use with mscipy.sttats.mquantiles. This can introduce fractional values. With the Integer logical type, we can set a column with fractional values to the int64 dtype and pandas will truncate the value. Our IntegerNullable logical type, which uses Int64 dtype, on the other hand, does not allow that. Because of this, we’ll need to make some change to allow partial dependence on IntegerNullable columns (I don’t view this as an integer nullable incompatibility, since I think pandas is probably right to not just silently truncate your data).
Code Sample, a copy-pastable example to reproduce your bug.
We will need to handle the IntegerNullable case, and while we're doing that, we should make the handling of fractional values for Integer columns explicit by rounding instead of letting the values get truncated.
The text was updated successfully, but these errors were encountered: