apache / apache/arrow

[C++] Adding tabular pretty printing of Table / RecordBatch

Open
#30,334 2 comments 0 reactions 0 assignees View on GitHub
Component: C++ Type: enhancement
Dominant language
C++
Stars
17.1k
Forks
4.3k
Avg merge
3d 13h
Merged PRs (30d)
88

Description

It would be nice to show a "preview" (eg xx number of first and last rows) of a Table or RecordBatch in a traditional tabular form (like pandas DataFrames, or R data.frame / tibbles have, or in a format that resembles markdown tables).

This could also be added in the bindings, but we could also do it on the C++ level to benefit multiple bindings at once.

Based on a quick search, there is https://github.com/p-ranav/tabulate which could be vendored (it has a single-include version).

I suppose that nested data types could represent a challenge on how to include those in a tabular format, though.

**Reporter**: [Joris Van den Bossche](https://issues.apache.org/jira/browse/ARROW-14799) / @jorisvandenbossche
#### Related issues:
- [PrettyPrint Improvements](https://github.com/apache/arrow/issues/33527) (relates to)

**Note**: *This issue was originally created as [ARROW-14799](https://issues.apache.org/jira/browse/ARROW-14799). Please see the [migration documentation](https://github.com/apache/arrow/issues/14542) for further details.*

Contributor guide

Open the contributing guide

Research direction

Start by reviewing the existing C++ pretty-printing entry points for Table and RecordBatch, then read the related PrettyPrint Improvements issue. The payload names no specific file or test. Done would be a defined tabular preview showing first and last rows, including a decided representation for nested data types.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
data-engineering
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.