ronisbr / PrettyTables.jl

Print data in formatted tables.
MIT License
404 stars 38 forks source link

Comparison with RStudio's `gt` package #173

Open greimel opened 2 years ago

greimel commented 2 years ago

There's a pretty recent R package by RStudio to create pretty tables.

It seems to be pretty feature rich and well thought through. They introduce their own names for table parts. Here's a screenshot from the package README.

image

Most of the elements are already available in, or have been asked for PrettyTables.

Introducing row groups might be interesting for printing GroupedDataFrames (cc @bkamins). Here's a screen shot from the RStudio blog

image
bkamins commented 2 years ago

This will be conveniently done when we add metadata to DataAPI.jl (and DataFrames.jl)

ronisbr commented 2 years ago

Thank you very much for this information!

By the way, I will change what I called row name to row label, which seems much better :D

Everything seems doable to implement except the spanner column label. It is somewhat difficult to do in text backend.

jariji commented 1 year ago

This diagram is missing support for hierarchical row labels like Pandas has

image

bkamins commented 1 year ago

I understand this is handled in the diagram above by groups.

Dale-Black commented 1 year ago

I am super keen on this gt Table equivalent in Julia. Based on this issue, it looks like this might already be possible with some elbow grease using PrettyTables and DataFrames? Do you know if this is true, and if so, are there any links that might help me get started?

ronisbr commented 1 year ago

This diagram is missing support for hierarchical row labels like Pandas has

I also agree with @bkamins that this feature is equivalent to row group.

I am super keen on this gt Table equivalent in Julia. Based on this issue, it looks like this might already be possible with some elbow grease using PrettyTables and DataFrames? Do you know if this is true, and if so, are there any links that might help me get started?

You can have some of the features using PrettyTables.jl in text, HTML, and LaTeX. Is there any specific use case you have in mind?

Dale-Black commented 1 year ago

I have a bunch of small dataframes that I would like to group into a formatted table like the gt table diagram shows

jariji commented 6 months ago

RStudio has a new blog post on the design of gt: https://posit-dev.github.io/great-tables/blog/design-philosophy/