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
There are numerical precision issues, e.g., round2(2436.845, 2) returns 2436.84. Changing z + 0.5 to z + 0.5 + sqrt(.Machine$double.eps) seems to work for me
Indeed, round_half_up(2436.845, 2) yields 2436.84. This function should probably have the same fix implemented, along with a test.
The text was updated successfully, but these errors were encountered:
From the StackOverflow post where I found this function, someone pointed out a bug in June:
Indeed,
round_half_up(2436.845, 2)
yields2436.84
. This function should probably have the same fix implemented, along with a test.The text was updated successfully, but these errors were encountered: