fix Bin transform to correctly round integral types