Open
Description
Hi,
When I print a vetcor of numeric values using 'as_tibble()', the value 9.995 is wronlgy rounded at 9.1.
Other values like 9.996, 9.994 are correclty displayed. It looks that this only occurs for this single value 9.995. When I try with 8.995 or 7.995, it works fine.
Here after is an exemple of the bug.
library(tidyr)
df <- tibble(val = c(9.994, 9.995, 9.996))
df # Incorrect: 9.99, 9.1, 10.0
df$val # Correct: 9.994, 9.995, 9.996
df <- tibble(val = c(8.994, 8.995, 8.996))
df # Correct: 8.99, 8.99, 9.0
df$val # Correct: 8.994 8.995 8.996
df <- tibble(val = c(7.994, 7.995, 7.996))
df # Correct: 7.99, 8.00, 8.00
df$val # Correct: 7.994 7.995 7.996
The version of R I'm using is : R version 4.5.1 (2025-06-13 ucrt)
Library tibble : Version 3.2.1
Library tidyr : version 1.3.1
Have a great day,
Metadata
Metadata
Assignees
Labels
No labels