New tibble pillar printing defaults too opinionated

Hey everyone,

I understand there are a few topics about the recent changes to how tibbles are printed (using pillar) and how not everyone is happy with those changes.

The solution appears to be that options are added to change how tibbles are printed.

I'm not sure whether I'm a big fan of that solution. There are multiple things that I do not like about the new printing defaults, which means I need to change multiple options at the start of my script just to get data to print in my expected way.

I also regularly teach R, so I do not want to change these defaults outside of a script, as this may cause unexpected behavior with my students.

Some examples I don't like about the new printing: negative numbers are red and numbers are truncated. It seems overly opinionated to say that negative numbers always have to stand out.

Normally I'm very happy with the opinionated defaults of the tidyverse, but this one is too bold for me. I'm quite curious to see what the general opinion is here.

Thanks!

8 Likes

Agree that the introduction of the new tibble printing method pushed the boundary of opinionated settings even more than rlang and tidyeval. I don't like variable names abbreviated, I don't like opinionated alignment around decimal point.

tibble::as.tibble(mtcars)
#> # A tibble: 32 x 11
#>      mpg   cyl  disp    hp  drat    wt  qsec    vs    am  gear  carb
#>  * <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
#>  1  21.0  6.00   160 110    3.90  2.62  16.5  0     1.00  4.00  4.00
#>  2  21.0  6.00   160 110    3.90  2.88  17.0  0     1.00  4.00  4.00
#>  3  22.8  4.00   108  93.0  3.85  2.32  18.6  1.00  1.00  4.00  1.00
#>  4  21.4  6.00   258 110    3.08  3.22  19.4  1.00  0     3.00  1.00
#>  5  18.7  8.00   360 175    3.15  3.44  17.0  0     0     3.00  2.00
#>  6  18.1  6.00   225 105    2.76  3.46  20.2  1.00  0     3.00  1.00
#>  7  14.3  8.00   360 245    3.21  3.57  15.8  0     0     3.00  4.00
#>  8  24.4  4.00   147  62.0  3.69  3.19  20.0  1.00  0     4.00  2.00
#>  9  22.8  4.00   141  95.0  3.92  3.15  22.9  1.00  0     4.00  2.00
#> 10  19.2  6.00   168 123    3.92  3.44  18.3  1.00  0     4.00  4.00
#> # ... with 22 more rows

In the example above, why does row 3 actually adds decimal point after 93 for value of hp? Values seem to be visually jumping and not necessarily easier to read.

Can we have voting for what level of "innovation" is right for default print method in tibble, please?

You can certainly upvote/add to the conversation in the relevant GitHub issue thread, though "voting for level of innovation" seems a bit abstract— but, re. your decimal point thoughts:

mara,

Thanks for pointing to issue discussions in {pillar}. I will leave a link here for anyone interested in chipping in: https://github.com/r-lib/pillar

1 Like

Just an added FYI/point of clarification, this isn't specific to pillar.