Hot answers tagged

8 votes
Accepted

Problem with table - \tabular vs \tabularx

Unlike the tabular* and tabularx environments, the tabular environment does not take a target width as one of its arguments. And, while employing the line-drawing macros of the booktabs package, one ...
  • 469k
6 votes

Latex custom table with different border colors

As a workaround, you can use {NiceTabular} of nicematrix for the small tabular in the second cell of your main tabular. The environment {NiceTabular} has its own key for the colors of the rules. \...
  • 31.1k
6 votes

LNCS: Large table in sidewaystable

No sidewaystable if you avoid lengthy repetition. \documentclass[runningheads]{llncs} \usepackage{booktabs,siunitx} \begin{document} \title{Paper Title Here ... } \begin{table}[htp] \caption{...
  • 1.1m
6 votes

LNCS: Large table in sidewaystable

You'll need to insert line breaks in almost all header cells. Since most of the headers appear to be acronyms, it's best to force the line breaks by hand; see the code below for how this may be done. ...
  • 469k
5 votes
Accepted

NiceTabular (NiceMatrix) Empty Line without Vertical Rules

You can use the rules of the classical {tabular} (of the package array which is loaded by nicematrix). That means that: you use the classical command \hline (and \hline\hline for the double rule); ...
  • 31.1k
4 votes
Accepted

How to Have a Table with Left and Right Vertical Boundary Lines but no Vertical Column Delineator?

If you have only 9 columns, you should only declare 9 columns, i.e. |lllllllll|. \documentclass[12pt]{report} \newif\ifShowSol \ShowSolfalse \usepackage{lipsum} \usepackage[most]{tcolorbox} \...
  • 2,315
4 votes

Allow table to go across left page border

I would suggest transposing the table so you don't have to negotiate different font sizes and angles for things to fit. \documentclass{article} \usepackage{booktabs,amssymb} \usepackage{makecell,...
  • 584k
4 votes
Accepted

Tabularray exceeding linewidth

Don't mix syntax from classic tables with tabularray ones: instead \newline you should use \\. Edit: Better spacin of cells' text you will get, if you will change `colspec˙ to: colspec = {X[0.9, l,h] ...
  • 276k
4 votes
Accepted

Error "Illegal pream-token" when using using LaTeX3 / expl3 with package array

the arraypackage documentation says Lamport’s original definition allowed you to do the following (although it was probably a mis-use of the system). \newcommand{\X}{clr} \begin{tabular}{...
4 votes

Align text horizontally in first 3 columns of a table with the top of figures in 4th column

You change the vertical placement of the TikZ picture by using the baseline key. We can specify here a coordinate somewhere in the diagram and PGF/TikZ will shift the picture so that this coordinate ...
3 votes

Error "Illegal pream-token" when using using LaTeX3 / expl3 with package array

Expand before evaluating \begin{tabular}: \documentclass{article} % ===>> The problem disappears if this line is commented out: \usepackage{array} % <<=== % Uncomment for older ...
  • 1.1m
3 votes

Add a curved arrow and a bracket to a table

With {NiceTabular} of nicematrix (and Tikz). \documentclass{article} \usepackage{nicematrix,tikz} \begin{document} \begin{center} \begin{NiceTabular}{ | l | l |} \hline letter & number \\ \...
  • 31.1k
3 votes

Align text horizontally in first 3 columns of a table with the top of figures in 4th column

You could use the adjustbox package (I removed the vertical lines, which won't work well in combination with booktabs): \documentclass{article} \usepackage{amsmath} \usepackage{graphicx} \usepackage{...
3 votes

Misalignment with bold font and additional symbols in siunitx

Your \hl{...} macro acts as a barrier which siunitx cannot look into. Perhaps use \hlx -0.123\sym{***} instead Where \NewDocumentCommand\hlx{}{\color{highlightColor}\bfseries} and \sym is modified to ...
  • 51.3k
2 votes

Latex custom table with different border colors

A tabularray solution is missing: \documentclass{article} \usepackage{xcolor} \usepackage{tabularray} \begin{document} \begin{table}[h!] \centering \begin{tblr}{colspec={Q[c,m,5cm, fg=green]...
  • 57.8k
2 votes
Accepted

Latex custom table with different border colors

You wouldn't necessarily need a table for this. You could place two boxes horizontally next to each other with a white space of your size: \documentclass{article} \usepackage[svgnames]{xcolor} \begin{...
  • 6,909
2 votes

Latex custom table with different border colors

Here is my solution using hhline and colortbl. \documentclass{article} \usepackage{hhline,colortbl} %New column type so that text is centered \newcolumntype{M}[1]{>{\centering\arraybackslash}m{#1}}...
  • 83
2 votes

Brace spanning multiple rows in a table and horizontal alignment

The environment {NiceTabular} of nicematrix is similar to the classical environment {tabular} (of the package array) but adds several features, including tools to add vertical braces. \documentclass{...
  • 31.1k
2 votes
Accepted

LNCS: Large table in sidewaystable

I could not help myself: this is just a spin on egreg's answer with some finetuning, while not changing anything profound: Streamlined legend (R: RF instead of (1) RF) Grouped columns with ...
  • 2,115
2 votes
Accepted

Forced place tables on 1 page, reduce space between them

LaTeX, at default settings, expect that 1/3 page is reserve for the text, Consequently in your page is not sufficient space for three floats. This yout overcome on the two ways: merge all floats in ...
  • 276k
2 votes

How to align cells vertically in a nested tabular?

I asked the question too quickly. The solution is counterintuitive, but still fairly simple. For the inner tabular, we need to add the option [t] for vertical alignment. I kept trying to set the ...
  • 241
2 votes

Equally sized column widths using tabular*

You may liked: Edit: Original MWE is now extended with preamble which OP show in question. Preamble is wee bit changed since packages amsmath and booktabs are now loadead as tblr libraries, as ...
  • 276k
2 votes

Align text horizontally in first 3 columns of a table with the top of figures in 4th column

I would like to recommend that you get rid of all vertical lines and replace most \midrule directives with \addlinespace instructions. I would also like to suggest that you center the text material ...
  • 469k
2 votes

Create a complex table with \multicolumn

Welcome to TeX.SE! Let me show you two possible solutions. One of them is closer to your handmade sketch, the other one I consider more professional as it adds some space at horizontal rules and ...
  • 2,315
2 votes

How can I make this table in an A4 sheet

For the last column you use X column, which is not defined (you not load tabularx package. You have mismatch in number of define table columns (9) and used (10), remedy is to add one more column in ...
  • 276k
1 vote

Table vertical centering : what am I doing wrong?

You need to move images baseline to images vertical center. This can be done on several vays, but seems (to my opinion) that valign of adjustbox is the most handy. Doing this you not need option m in ...
  • 276k
1 vote

Table vertical centering : what am I doing wrong?

It seems to me that: for the vertical alignment of the images, we need h and not m; the text of column 2 is aligned vertically with the = of column 4, if you want to align vertically with the image, ...
  • 2,147
1 vote

Allow table to go across left page border

If, for some reason, you don't want to transpose the table and you don't want to rotate the column headers by 90 degrees, you can still make the fit inside the width of the text block by (a) issuing ...
  • 469k
1 vote
Accepted

Vertical alignment of a list in a table using tblr

Try the following: \documentclass{article} \usepackage{geometry} \usepackage{enumitem} \usepackage{tabularray} \UseTblrLibrary{varwidth} % <--- \begin{document} \begin{table}[ht] \...
  • 276k
1 vote

Allow table to go across left page border

Edit (2): Now considering the edited question. ANd also load last version of table code. Now the first row is correctly spaced. i.e. aligned at bottom of the row. One way is to rotate the columns' ...
  • 276k

Only top scored, non community-wiki answers of a minimum length are eligible