# widening toprule et al. in booktabs

I have two tables side by side. I want to trick readers into seeing this as one table, by widening the toprule command.

In the MWE below I want to join the toprule of the cats table to the dogs table, and the same for the bottom rule and mid rules.

This is a sneaky way of entering table data by order of column, rather than by rows.

The MWE is

\documentclass[10pt]{article}
\usepackage{booktabs}
\begin{document}
\begin{tabular}[t]{l}\toprule
cat\\
cat\\
cat\\
cat\\
cat\\
cat\\\bottomrule
\end{tabular}
\begin{tabular}[t]{l}\toprule
dog\\
dog\\
dog\\
dog\\
dog\\
dog\\\bottomrule
\end{tabular}
\end{document}

• Isn't it just the space after \end{tabular} ? Add a % right after to remove the space Nov 29, 2015 at 17:14
• yes! but the other guy got the answer first. sorry!
– Tim
Nov 29, 2015 at 17:16

This is very simple to achieve ... just ad % between tables to prevent space between them:

\documentclass[10pt]{article}
\usepackage{booktabs}
\begin{document}
\begin{tabular}[t]{l}\toprule
cat\\
cat\\
cat\\
cat\\
cat\\
cat\\\bottomrule
\end{tabular}%
\begin{tabular}[t]{l}\toprule
dog\\
dog\\
dog\\
dog\\
dog\\
dog\\\bottomrule
\end{tabular}
\end{document}

• yes perfect. I still don't understand the rules of %.......my bad.
– Tim
Nov 29, 2015 at 17:16
• The % make that \end{tabular} is continued without any spaces with begin{tabular} in the next editor line. The same result you obtain if you write  ...\end{tabular}\begin{tabular} .... Nov 29, 2015 at 17:21

You can simply wrap the tabulars inside a tabular. For example:

\documentclass[10pt]{article}
\usepackage{booktabs}
\begin{document}
\begin{tabular}{@{}c@{}c@{}}\toprule
\begin{tabular}[t]{l}
cat\\
cat\\
cat\\
cat\\
cat\\
cat\\
\end{tabular}
&
\begin{tabular}[t]{l}
dog\\
dog\\
dog\\
dog\\
dog\\
dog\\
\end{tabular}\\
\bottomrule
\end{tabular}
\end{document}