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
I have encountered an example of a tibble object being printed out, where the last (non-zero) digit appears to be wrongly truncated from the printing.
Here is the actual example R code which produces the issue. [I am using RStudio.]
library(tidyverse)
library(compositions) # this is on CRAN
data(ArcticLake) # from compositions package; this is a matrix so convert to tibble belowrounderr<-ArcticLake|>
as_tibble() |>
mutate(Total=sand+silt+clay) |>
filter(abs(Total-100.0) >0.05)
print(rounderr)
The last column in the second row should be 100.5. But clearly it has lost the tenths digit.
Using the View() function, I could explore the structure of the tibble in question visually. Here is a screenshot to show that the relevant value is actually stored correctly.
I checked the help pages, expecting to see this was a consequence of a pure '.5' being rounded, which is somewhat more subtle than run-of-the-mill rounding. I could not find any such information -- obviously if I have missed this I would be very grateful to have it pointed out!
RStudio 2024.09.0+375 "Cranberry Hibiscus" Release (c8fc7aee6dc218d5687553f9041c6b1e5ea268ff, 2024-09-16) for macOS
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) RStudio/2024.09.0+375 Chrome/124.0.6367.243 Electron/30.4.0 Safari/537.36, Quarto 1.5.57 (/Applications/quarto/bin/quarto)
The text was updated successfully, but these errors were encountered:
Ahh. Three sig figs would explain it. Apologies for taking up the team's time.
Perhaps I still missed it in the package help pages proper. But if not, maybe the behavior could be mentioned there somewhere. I am agnostic about the raised trailing digit issue, but that's my N=1 opinion :)
I have encountered an example of a tibble object being printed out, where the last (non-zero) digit appears to be wrongly truncated from the printing.
Here is the actual example R code which produces the issue. [I am using RStudio.]
The output is
The last column in the second row should be 100.5. But clearly it has lost the tenths digit.
Using the View() function, I could explore the structure of the tibble in question visually. Here is a screenshot to show that the relevant value is actually stored correctly.
I checked the help pages, expecting to see this was a consequence of a pure '.5' being rounded, which is somewhat more subtle than run-of-the-mill rounding. I could not find any such information -- obviously if I have missed this I would be very grateful to have it pointed out!
Here is sessionInfo():
Here is my RStudio info:
The text was updated successfully, but these errors were encountered: