LaTeX forum ⇒ Graphics, Figures & TablesChoosing between table packages

Information and discussion about graphics, figures & tables in LaTeX documents.
noah
Posts: 4
Joined: Mon Oct 02, 2023 3:21 am

Choosing between table packages

Postby noah » Mon Oct 16, 2023 10:04 pm

Hello!

I am a first time poster here, so please excuse (and correct) any formatting or best-practice errors that I make. I want to preface my question by stating that I am a novice-intermediate coder (mechanical engineer by training) so I understand some general coding vernacular in casual conversation. I have been using LateX for 2 months now. Question for LateX veterans: a) what table environment/package do you use now; b) should a beginner use this environment/package or start with something else? The environments/packages that I've used are tabular/tabular*; tabularx/tabulary. I tend to use the tabularx package for easy specification of total table width, but then I struggle to make changes on a column/row or cell/cell basis. I realize there is no one correct answer, but I tend to prefer more verbose but elegant solutions. What do you all recommend?

If any of you are familiar with the Microsoft Word Table environment, I would prefer solutions that allow for that amount of customization with the smallest penalty in complexity as possible. I find that I am most consistently fighting horizontal/vertical justification of text and specifying fixed cell widths/heights.

Any help would be appreciated! Thank you in advance! If it would be easier to explain in a call, I can provide my discord.

Noah

Recommended reading 2021:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics
User avatar
Stefan Kottwitz
Site Admin
Posts: 10164
Joined: Mon Mar 10, 2008 9:44 pm

Choosing between table packages

Postby Stefan Kottwitz » Sat Oct 21, 2023 2:45 pm

Hi Noah,

welcome to the forum!

The array package is a great essential package. For instance, it allows the definition of new column styles.

The tabularx package is very useful in the way you mentioned it. tabulary does a similar job but tabularx is easy to understand and popular.

The longtable package is handy when your tables get bigger than the page height.

The booktabs package is great for beautiful table design.

The tabularray package is very new and interesting, though it's perhaps not easy to understand the concept of it.

Stefan
LaTeX.org admin

FPantigny
Posts: 4
Joined: Wed Jul 26, 2023 10:37 pm

Choosing between table packages

Postby FPantigny » Wed Apr 24, 2024 7:38 pm

I suggest my package nicematrix, which, despite its name, is able to deal with tabulars. It loads the package array and can be used in conjunction with the package booktabs.

The main advantage of nicematrix is that it creates PGF/TikZ nodes under the cells, rows and columns. Several functionalities provided by nicematrix use these nodes but the final user may also use them. Hence, it's always possible to draw whatever graphical element you want.

The main disadvantage of nicematrix is that its tabulars can never be broken by an end of page...


Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: No registered users and 12 guests