Questions tagged [booktabs]

A package providing some additional commands to enhance the quality of tables in LaTeX.

Filter by
Sorted by
Tagged with
4
votes
2answers
55 views

Put a symbol to the side of a row in a booktabs table

I would like to annotate one or more rows of a table with a star; the star should not be part of the table. I am using booktabs, so I cannot just add another column, or add the star to the rightmost ...
2
votes
2answers
31 views

When coloring table rows, there is white space between the line and the \toprule and the \bottomrule

As stated in the headline, I am trying to add color to my tables but it seems the booktab package leave extra white space between \toprule and \bottomrule that are not covered by \xcolor \...
1
vote
1answer
30 views

Using numprint to round numbers within a single column in a table

I like to use numprint to format my tables with numerical values, as it improves readability and alignment. However, sometimes I want to use a different rounding setting for a particular column, and ...
0
votes
3answers
32 views

Rowcolor overhang with makecell

When I trim the sides of tables using @{}, the \rowcolor hangs over the sides. I've fixed this with <{\kern-\tabcolsep} on the first and last column (according to this question). However, if \...
0
votes
1answer
27 views

Rowcolors in a longtable with three parts

I have a longtable inside a ThreePartTable environment and I want to have alternating row colors across page breaks. I want to have no color on the first row, since the header is also colored. The ...
1
vote
2answers
51 views

How to remove blank spaces around table rules

I am trying to produce a colored table but the separation lines and the border lines are creating blank spaces that ruins the aesthetics of the table. I wish to remove them. Here is the code I'm ...
3
votes
3answers
83 views

Using booktabs and \tabular I get a heavy vertical rule on the right edge only

My table is filled and all boxes are filled. I have made similar tables elsewhere in the document with no issues. (It is a conjugation table for verbs in a conlang I'm making, if you're wondering.) ...
0
votes
1answer
20 views

Adding rules to the tabularx environment

How does one automatically add a \bottomrule at the end of a tabularx environment? \documentclass{scrartcl} \usepackage{tabularx} \usepackage{booktabs} \usepackage{etoolbox} \newenvironment{...
2
votes
2answers
82 views

\toprule is not spanning the width of the table

I am trying to create a landscape table that spans the vertical length of a page. The following is what I get: The table almost looks good, except for the following: The \toprule, \midrule and \...
2
votes
1answer
52 views

Why this simple booktabs code does not work?

I have the following code: \documentclass{article} \usepackage{booktabs} \begin{document} \begin{table} \begin{tabular}{SSSS} 1& small copper ring & small aluminum ring & ...
4
votes
3answers
64 views

Tabularx, landscape, \toprule \midrule do not fully underline row

Somehow \toprule does not underline the whole row of my table. Hopefully, someone can explain to me what I am doing wrong. My ultimate goal is to create a table similar to: Copy of my shortened code: ...
0
votes
2answers
44 views

No vertical lines in multirow with booktabs

I want to have a table that looks like this but without the horizontal lines above and below MULTI: My code is the following: \documentclass{article} \usepackage{tabularx} \usepackage{booktabs} \...
0
votes
2answers
36 views

Extra gap between the columns in colored tables

Tables again. I want to color several rows in the table and use colortbl package. Everything works fine. Now I want to add extra gap between the first and the second column to make the table more ...
2
votes
3answers
62 views

Table out of the right margin of the template

I am using booktabs library to make my table in latex. However, I noticed that due to the size of the table it goes out of the right margin. I tried to follow several recommendations from several ...
0
votes
0answers
56 views

How to edit/create table optimal in Latex?

I am familiar with some latex online editors like tablesgenerator ot latex-tables, however often I want to directly see the output in my own code, so I edit the tabular directly in my code. Despite ...
2
votes
2answers
80 views

FIll empty cells automatically with dummy values

I am working on layoutin a huge table for my thesis. For this it would be great that the tabl is not just blank, it should contain all empty cells with dummy values like x It simply could do so by ...
0
votes
1answer
74 views

Thickness of toprule and bottomrule when resizing table

I have the problem that when my table gets too wide so that I have to resize it, the thickness of \toprule and \bottomrule won't show any more. When I zoom in I can see that there still is a thickness ...
1
vote
2answers
57 views

Rotated multi-column header in booktabs

I want to gernerate a cross table with booktabs. Therfore, I have 2 data sets I want to compare to each other. The table should look like the pic below but I do not get it to write the vertical ...
5
votes
1answer
117 views

xltabular breaking booktabs

I want to have a page-filling and -breaking longtable, so I decided to try xltabular. Unfortunately xltabular seems to screw up the booktabs rules in the normal tabular environments, see: \...
1
vote
1answer
31 views

Cmidrule align same line using arraystretch

Consecutive cmidrule need to align same line(as given in the second part of table) even using arraystretch? \documentclass{article} \usepackage{booktabs} \usepackage[table]{xcolor} % Correct for \...
2
votes
2answers
53 views

pgfplotstable: change the color of a cell's content in string type while maintaining the style

Expanding the topic covered in pgfplotstable: how can I change the color of a cell's content while maintaining the style?, correctly resolved by @frougon, I need to change the color of a single cell ...
0
votes
0answers
24 views

Double line in cmidrule narrows subsequent cmidrule

I had applied two cmidrule in the table but subsequent cmidrule not aligned same line, please give solution using booktabs. Already there is an option hhline, but rule crop cannot done both side of ...
2
votes
3answers
786 views

How can I to do this?, but with lines join

I used Excel2Latex % Table generated by Excel2LaTeX from sheet 'Sheet1' \begin{table}[htbp] \centering \caption{Add caption} \begin{tabular}{|r|r|r|r|r|} \cmidrule{1-1} \rowcolor[rgb]{1,1,...
1
vote
1answer
36 views

Two tables next to each other

How can I get two tables next to each other? MWE: \documentclass{article} \usepackage{multirow} \usepackage{amsmath} \usepackage{setspace} \usepackage{booktabs} \begin{document} \begin{table}[...
0
votes
1answer
24 views

Fixing multirow and multicolumn

How can I add (fix) the last two rows? I need add one more row to each of one: \documentclass{article} \usepackage{multirow} \usepackage{amsmath} \usepackage{booktabs} \begin{document} \begin{table}...
0
votes
0answers
20 views

Booktabs rules rendering less than full width [duplicate]

Using the booktabs package, I have generated a relatively nice table but there is one slight problem: The zebra colouring on the rows extends further than the top/mid/bottom rules. This is a bit ...
1
vote
2answers
38 views

Remove multicolumn from Tabular

I'm trying to remove the first column (RoE) in this example: \documentclass[11pt]{article} \usepackage{multirow} \usepackage{tabularx} \usepackage{booktabs} \begin{document} \begin{table}[htbp] \...
1
vote
0answers
37 views

Centering table cells about decimal point with bold and asterisk, for dynamically generated tables

I am using PdfLaTeX (MiKTeX) called via R-Brew to dynamically populate and generate a LaTeX table. Use of R tables does not support all of the statistics, and is not flexible enough for the tables I ...
1
vote
1answer
56 views

Moving column to left

I found this superb example in the latex wikibook. \usepackage{booktabs} \begin{tabular}{llr} \toprule \multicolumn{2}{c}{Item} \\ \cmidrule(r){1-2} Animal & Description & Price (\$) \\ ...
0
votes
0answers
34 views

cmidrule narrower

While we inserting \cmidrule width or color in tables second \cmidrule get narrower, please how to fix, please find MWE file: \documentclass{book} \usepackage{ragged2e} \usepackage{dcolumn,booktabs,...
1
vote
2answers
62 views

Symmetrical table, is booktabs recommended?

I have the following table, used with booktabs. I call it "symmetric" as three states of two variables are compared, but it does not matter if a variable is written along the rows or along the ...
3
votes
2answers
80 views

modifying default tabular behaviour

I basically do all my tables the same way: Is it possible to make tabular automate the \toprule, \midrule, \bottomrule and \hdashlines? \documentclass{article} \usepackage{booktabs,array,arydshln} \...
2
votes
1answer
38 views

Table with two tabulars of different width

I have a table which consists of two parts (tabulars). It looks similar to the excerpt attached below. Now what I would like to do is format the second part (tabular) of the table nicely. That means: ...
0
votes
1answer
33 views

Making spacing after rule at top of page in booktabs longtable consisting with that after other rules in the same table

Appropriately placed, the longtable package code \midrule\endhead places a horizontal rule before the first row on each page after the first produced by a longtable environment. The below simple code ...
3
votes
4answers
294 views

Table alignment (make the content centre)

I want to make the content center, i have out of idea what else I can change. \documentclass[12pt,oneside]{book} \usepackage{showframe} \renewcommand\ShowFrameLinethickness{0.15pt} \renewcommand*\...
0
votes
1answer
129 views

How to create table with booktabs package?

I would like to create the following tables with the booktabs package but I am not quite sure how to do that and Any help is greatly appreciated!
2
votes
2answers
161 views

Colored tables with booktabs, makecell and cellspace

While experimenting with different table-packages, I realised, that each package basically stands for itself and often lacks in compatibility with other great packages. So I tried to create a table ...
0
votes
2answers
60 views

gap between toprule and vertical lines in tabular

In this MWE \documentclass[]{article} \usepackage{amsmath} \usepackage{booktabs}%added 8/16/2019 \setlength\heavyrulewidth{0.5ex} \begin{document} \small \begin{tabular}[c]{|p{1.5in}|p{...
0
votes
1answer
82 views

Fix errors for a specific table

I have a table with this MWE. \documentclass[a4paper,12pt]{article} \usepackage{amsmath,amssymb} \usepackage{booktabs,makecell} \begin{document} \begin{table}[htb] \captionsetup{justification=...
3
votes
3answers
561 views

Continuous vertical line using booktabs in tabularx table?

How can we draw a continuous vertical line using booktabs in table? What is the simplest method to maximise the width of a table? There are lots of methods, very confusing. \documentclass{article} \...
1
vote
2answers
117 views

Grouping rows of a table with brackets (to shrink table size)

I have a table using rules from booktabs. However, I have vertical space constraints and don't want to use subcaption with their subtable. I also have horizontal space constraints, so the column for ...
0
votes
3answers
166 views

Tabularx and itemize missing item

when I do this : \begin{tabularx}{\textwidth}{|p{5cm}|p{5cm}|} \toprule \textbf{KPI} & \textbf{Description} \endhead \toprule \rowcolor{darkgrey} \textbf{The percentage of health and safety ...
1
vote
1answer
49 views

Using booktabs with newcommand

I'm relatively new to defining commands and environments. I'm trying to make several tables (all of which follow a template), and thought that defining myself a new command would simplify the code. ...
1
vote
1answer
54 views

Formatting a table with shortened midrules and centred headings

I have the following table and I am trying to align the 2016 and 2017 values. At the moment the code creates a straight line joining the 2016 and 2017 values. I am trying to get it to look like the "...
1
vote
1answer
34 views

How to assign merged cells to the right colunm?

I've been trying to make a table using the \booktabs pagackage and following this model with some tweaks. However, the merged cells end up in the wrong column, namely the first column and not the ...
2
votes
2answers
152 views

Fill between \toprule and \midrule

I've already tried one approach for this and had issues (Clear rowcolor at midrule) and now I've started having more. So instead of trying to fix that approach I thought it could be worth seeing what ...
0
votes
2answers
47 views

How to center the contents of the first column?

How to center only the contents of the first column, without centering anything else, including the header of the first column? \documentclass{article} \usepackage{booktabs} \usepackage{array} \begin{...
0
votes
0answers
32 views

cmidrule overlap [duplicate]

I notice when I have a \cdmidrule command on neighboring columns \cmidrule{5-6} \cmidrule{7-8} that it produces a single straight line between columns 5 and 8. Whereas what I want (for visual ...
0
votes
2answers
91 views

How to get continuous vertical line without breaking inside array environment?

I am facing a problem in the following code, i found that there is a breaking in two vertical lines as shown in red mark when i used the command \cmidrule[1pt](r{-1.0em}){1-4} inside array environment,...
1
vote
1answer
83 views

vertical border in longtable + booktabs + repeating table header

This seems to be a bug in booktabs + longtable when there are repeating header rows. I got an error report on this from the r package kableExtra. https://github.com/haozhu233/kableExtra/issues/377 ...

1
2 3 4 5
7