{tables} is about the tabular environment and related packages such as {array}, {booktabs}, {tabularx} and {longtable}. For questions about the table environment (i.e., about floating or positioning), use {floats} instead.

learn more… | top users | synonyms (2)

30
votes
5answers
53k views

LaTeX tables: How do I make bold horizontal lines (typically \hline)?

The title says it all: In LaTeX tables: How do I make bold horizontal lines (typically \hline)?
17
votes
2answers
604 views

How to put the list of figures into a table

How can I get a “list of figures” of the following type? List of figures Exactly, this list of figures is set as a table. I know this cannot be obtained by the command \listoffigures directly, but ...
11
votes
2answers
723 views

PGFplotstable: Is it possible to set a number format for a *row* instead of a column?

Using pgfplotstable, it's straightforward to set a column number format using columns/(columnname)/.style={(format)} What I would like to do is change the number format of a particular row. In my ...
11
votes
5answers
7k views

Align Note below table

My question concerns the "Note" below the table. This is my code: \begin{table} \begin{center} \caption{ Descriptive statistics of total sample based on modified data set}\label{table:descrtotal} ...
8
votes
2answers
8k views

How to highlight table rows by colors in Beamer

I would like to highlight rows in tables, in rowwise, that is I would like to highlight row 1 in red, then make row 1 in black but row 2 in red, etc. How can I manage to do so in Beamer?
7
votes
4answers
6k views

Table with foot note

I have a table and some of the number inside has some symbol like * and ** which should be explianed as footer ( at the end of the table not the page) I dont know how to do that and I dont want to ...
6
votes
2answers
4k views

Shrink table to fit on a page, or keep it as it is

I am using \resizebox{\columnwidth}{!}{% ... %} to fit a table which might be too wide onto a page by scaling it down. However, my problem is that if the table is smaller than the column width, it ...
24
votes
3answers
28k views

tabular vertical alignment to top?

I'm trying to create a simple tabular with two cells of text and two images below them like so: \begin{tabular}[h]{ c | c} \emph{Normal} & \emph{Cone} \\ ...
12
votes
2answers
1k views

vspace before itemize in a Table cell, tabular vs longtable

In the following MWE, one sees the difference between tabular and longtable, with respect to the vertical space before an itemize, inside a cell : \documentclass[12pt]{article} ...
11
votes
2answers
6k views

Evenly distributing column widths

Consider the following hunk of code: \begin{tabular}{| c | c | c | c | c | c | c | } \cline{2-7} \multicolumn{1}{c}{} & \multicolumn{3}{|c|}{Fantastical aardvarks} & ...
10
votes
1answer
1k views

Create a vertical line in a table that spans a range of rows but not all rows

I'm interested in methods to create a vertical line in a table that spans a range of rows but not all rows. I've found one solution below, but is there another solution such as \cline which allows ...
7
votes
1answer
7k views

Vertical Alignment in multirow using cells with >1 lines

I want to vertically align (best would be to center) the text ("TEST") in the left (yellow) column of the following table. It works fine with multirow when every row has exactly the hight of one line: ...
7
votes
3answers
934 views

Keep first column on every page of long sideways-table

I have a table with a lot of columns, so I am going to make it landscape.The very first column is a sort of header, so I would like to repeat it on every page. Is there a way to do that?
6
votes
2answers
1k views

Crop entire document around figure

Have you ever submitted a LaTeX paper to a journal that wants separate figures? When you want to include a figure composed of a table of images, you must build it separately. When I run latexpdf, I ...
6
votes
3answers
12k views

how to vertically align a cell in a table?

I have a table that I define \begin{tabular}{lllllllllllll} \includegraphics[width=7.3in]{img1.pdf} & \includegraphics[width=7.3in]{img2.pdf} & \includegraphics[width=7.3in]{img3.pdf} & ...
4
votes
4answers
1k views

How to obtain width of longtable?

I need to create multiple tables of the same width, one of them needs to be a longtable due to spanning multiple pages. I could set the width of all of them to a predefined value. However, I would ...
4
votes
2answers
2k views

Clickable Table Footnote

I'm trying to have some clickable footnotes within tables. I tried using \footnote{}, it does create a link but there's no footnote text associated with it. \footnotemark[number] along with ...
12
votes
2answers
7k views

How to color the font of a single row in a table?

I have a table and I want to make the font color red for just one row (not the background). How do I do that? Here's my table: \begin{tabular}{ l | l l l l } & 1 & 2 & 3 & 4 ...
12
votes
3answers
331 views

Expansion of first token in a tabular cell

Background I currently do some work on the collcell package which collects the content of a tabular/array cell and provides it to a user defined macro, e.g. using ...
11
votes
1answer
583 views

Tables in Latex with diagonal first row

I'm trying to create a table with a diagonal first row, like in how-to-draw-diagonal-table-borders-in-latex-like-in-excel I've looked through the documentation for PGF-TiKZ, but am still unsure as to ...
11
votes
3answers
445 views

Define a table one column at a time instead of one row at a time

Is there a way to define a table like so? \begin{tabular}{|c|c|} column 1, row 1 \\ column 1, row 2 \\ column 1, row 3 \\ column 1, row 4 \\ column 1, row 5 \\ && ...
10
votes
3answers
540 views

Control order of columns in table

Is there maybe a way to define the order of columns oneself? Say I have \begin{tabular}{ l l l } A1 & C1 & B1 \\ A2 & C2 & B2 \\ A3 & C3 & B3 \\ \end{tabular} but ...
9
votes
2answers
293 views

Best practices longtable

I have a long table with the explanation of 50 items (the MWE displays only 9). I believe this is hard to read. How do I make it easy to read? \documentclass[10pt,cleardoublepage=empty,twoside]{book} ...
9
votes
2answers
1k views

How to include tabularx/y in a new environment?

I am looking for a way to define a customizable environment for tables in my latex documents. This means: caption and label width of table customized column format (tabular preamble) While this ...
8
votes
2answers
472 views

How to shrink a table automatically so that it fits onto a page?

I have a table that looks like this: \begin{table}[h] \centering \caption{MYCaption} \label{tbl:table1} \begin{tabular}{|l|l|l|l|} \hline \rowcolor[gray]{.8} \multicolumn{4}{|c|}{Team 1}\\ \hline ...
6
votes
2answers
796 views

Underbrace under table, stretching over multiple columns

I want to notate some information to table column groups, using underbraces. So there should be an \underbrace under the table, that stretches over multiple rows. I tried the following: ...
6
votes
2answers
745 views

Error with hyperref + tabular + footnotes in tabular

Here's the code: \documentclass[12pt,letterpaper]{article} \usepackage{array} \newcommand{\fntxt}[1]{\footnotetext{#1}} \newcommand{\fnstep}{\stepcounter{footnote}} ...
6
votes
4answers
1k views

Footnotes in Tabulars?

Is there a simple, elegant solution to add footnotes in a table (tabular)? Preferably, the solution can also support the cleveref package. EDIT: My intended effect is that, the footnotes should be ...
6
votes
1answer
900 views

tabular, siunitx and input - `Extra }, or forgotten $.`

I'm trying to include data into a tabular environment \usepackage{booktabs} \usepackage{siunitx} \begin{table} \begin{center} \begin{tabular}{SSSS} \toprule {$na^3$} & ...
5
votes
1answer
4k views

How to fit a wide table

I see that many people have already asked the same question, but unfortunately I can't make it work for me at the moment. So, once again, how can I centre and fit tables larger than that to my report? ...
5
votes
1answer
862 views

Tabular with arrows or lines between some cells

I have a table like the one below and want to write this in Latex. what would be the best aproach? I have tried it with Tikz where i can nest a Table but failed with the lines wich connect the ...
5
votes
1answer
623 views

Page breaks in table rows

I want to make a document that contains a synopsis of events, like YEAR HISTORY CULTURE SCIENCE 1770 History para- culture para- science para- ...
5
votes
1answer
275 views

Table with a numbered list

What is the best way to make a table/list that looks like this: 1. Item 1 subitem type date subitem type date 2. Item 2 subitem type date ...
4
votes
1answer
427 views

Add Table in Header with image

I'm trying to create question paper using Latex. Sample copy of expected header for first page is mentioned below. Note: Image above "First Page Header". Can you please suggest, how can I add table in ...
4
votes
1answer
6k views

Regression tables made with esttab in Stata have columns with different widths, using LyX

I am relatively new to LyX and I am trying to output regression results into TeX code, and then insert the resulting tables in a LyX document. The command I use to create the table is: reg y1 x1, ...
4
votes
1answer
1k views

Multiple references to the same footnote inside a table environment

I followed the steps in this answer to get multiple references to the same footnotes working. As shown in this minimal example, the solution is working great for footnotes in the text, also getting ...
4
votes
2answers
526 views

generating LaTeX tabular code during compilation

I use LaTeX for scientific reporting in brain imaging (fMRI). I have a tabular array in LaTeX, that contains quite a lot of rows and columns, which both are brain regions and in the each intersecting ...
3
votes
1answer
304 views

Why does adding color to a table row increase the height?

I'm trying to make a beamer slide containing a table with the text in a row styled in a different color. However, the row's height increases when colored, as opposed to the default. The same problem ...
20
votes
3answers
5k views

How to specify a fixed height for all rows in a table?

I have something like this: \newcolumntype{C}[1]{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}} \begin{tabular}{| c | C{3cm} | C{4cm} |} Short Text & Short Text & Short Text ...
17
votes
3answers
2k views

Is there something like “sidewayslongtable”?

Unfortunately my table is too wide to use longtable. In sideways it fits on width. Unfortunately it's too long to fit on one page. Is there something like sidewayslongtable, a way to combine ...
13
votes
2answers
6k views

Raggedleft paragraph in a table

I am trying to typeset a table of two columns, where each column consists of paragraphs and the paragraphs in the right hand column are set raggedleft. Here is a minimal example of the code I thought ...
9
votes
1answer
1k views

Is it possible to have multiple paragraphs inside a multicolumn using xcolor or a replacement?

I am getting information written by users in many lines, paragraphs, and I have to put those inside a table, I would like to know if it is possible to instruct LaTeX to accept paragraphs inside a ...
9
votes
3answers
10k views

Control spacing around table caption

I want to put several tables in the same table float like this: \documentclass[a4paper, 12pt]{article} \usepackage[T1]{fontenc} \usepackage{subfig} \begin{document} \begin{table} \caption{Internal ...
8
votes
2answers
360 views

How to check if a column type is defined?

Column types for tables can be defined and overwritten with \newcolumntype. I would like to know if a column type is already defined for an example which shall only be executed in the case where the ...
8
votes
1answer
4k views

How to divide a table row into several columns?

I have a table with two columns. In the first column there is no multiple column. But there are 11 multiple columns in the second column. The format looks like: | A | B ...
6
votes
2answers
546 views

Hebrew vs. German/English translation side-by-side

I am having the following problem: I have Hebrew texts and want to put translations (and other information) right next to it in a nice way. (Previously I used the old Nisus Writer for Mac which for ...
5
votes
3answers
170 views

Creating a special table with different row lengths in latex

How can I have a table like the following picture in latex?
5
votes
3answers
192 views

Troubles with column width in the tables headings

Well, we all know that compose tables in LaTeX is not easy, however, despite the large number of existing packages and options to facilitate this, I still have some problems I could not solve, and I ...
5
votes
1answer
2k views

How to vertically and horizontally centre text and images in (different) table cells?

I have a table which contains images in one column. I would like the first column to have text centred vertically and horizontally. I would like the second column to have text left justified and ...
4
votes
3answers
222 views

Can't include a 'tabu' inside \newenvironment with cells in the postamble

I'm trying to include a tabu inside a new definition of an environment but it fails if the postamble (enddef) of the new environment includes tabu's contents, so cells. With tabular or tabular* works. ...