1

the vertical lines of my first row aren't joining my \toprule despite having specified vertical separators in the multicolumn command. Please help!

\begin{table*}[!h]\centering 
    \ra{0.8} 
    \begin{tabular}{|c|  c  c  c  c  c   c  c | c  c  c| }
        \toprule
        & \multicolumn{7}{|c|}{Blast facing side} & \multicolumn{3}{c|}{Rear face of plate}\\ 
        Plate & \multicolumn{4}{|c}{Deposition of burned material} & \multicolumn{3}{c|}{Dome inner surface} & Darkened & Ring around & Lines next \\ 
        & None & Fine & Moderate & Dense & Smooth & Dimples & Cross hatch & dome & dome & to dome \\ 
        \midrule
        BC50SOD & $\checkmark$ &  &  &  & $\checkmark$ &  &  &  &  &  \\ 
        BC60SOD &  & $\checkmark$ &  &  & $\checkmark$ &  &  &  &  &  \\ 
        BC75SOD &  & $\checkmark$ &  &  & $\checkmark$ &  &  &  &  &  \\ 
        36C50SOD &  &  & $\checkmark$ &  &  &  &  &  &  &  \\ 
        36C60SOD &  &  & $\checkmark$  &   &  & $\checkmark$ & $\checkmark$ &  & $\checkmark$  & $\checkmark$ \\ 
        36C75SOD &  &  & $\checkmark$ &  &  &  & $\checkmark$  & $\checkmark$ &  & $\checkmark$  \\ 
        36C80SOD & &  & $\checkmark$ &  &  &  &  &  & $\checkmark$ & $\checkmark$ \\ 
        36C90SOD & &  & $\checkmark$ &  &  &  & $\checkmark$ & $\checkmark$ &  & $\checkmark$ \\ 
        36C100SOD & &  & $\checkmark$ &  &  &  &  & $\checkmark$ &  & $\checkmark$ \\ 
        36C120SOD & &  & $\checkmark$ &  &  &  & $\checkmark$ &  & $\checkmark$ &  \\ 
        \bottomrule
    \end{tabular} 
    \caption{caption} 
    \label{tab:restults} 
\end{table*}

enter image description here

  • What is the \ra command? Please always post full compilable posts. – Bernard Oct 24 '16 at 8:33
  • \newcommand{\ra}[1]{\renewcommand{\arraystretch}{#1}} – user3079617 Oct 24 '16 at 8:50
1

You're using booktabs, which should not be used with vertical rules if you want professional-looking tables.

The reson for this behaviour comes the fact that these rules add some vertical padding around them which breaks vertical rules. If you want to have full vertical rules, you have to delete this padding, adding

\setlength{\aboverulesep}{0pt}
\setlength{\belowrulesep}{0pt}

but you lose one of the main interests of booktabs.

You can replace this padding loading cellspace, which allows to define a minimal vertical spacing at the top and bottom of cells, or makecell which allows to add a fixed spacing at the top and bottom of cells and, incidentally, also defines lines of variable thickness.

  • Thanks this seems to do the trick for the most part. There are still very tiny little gaps at the top. But of course now all my other tables are ruined! – user3079617 Oct 24 '16 at 8:47
  • You can make the changes local to this table: the changes need not be in the preamble. – Bernard Oct 24 '16 at 8:55
0

Use \hline instead of \toprule and \midrule or simply do not use vertical lines at all!

\def\arraystretch{0.8}
    \begin{tabular}{|c|  c  c  c  c  c   c  c | c  c  c| }
        \hline
        & \multicolumn{7}{|c|}{Blast facing side} & \multicolumn{3}{c|}{Rear face of plate}\\ 
        Plate & \multicolumn{4}{|c}{Deposition of burned material} & \multicolumn{3}{c|}{Dome inner surface} & Darkened & Ring around & Lines next \\ 
        & None & Fine & Moderate & Dense & Smooth & Dimples & Cross hatch & dome & dome & to dome \\ 
        \hline
        BC50SOD & $\checkmark$ &  &  &  & $\checkmark$ &  &  &  &  &  \\ 
        BC60SOD &  & $\checkmark$ &  &  & $\checkmark$ &  &  &  &  &  \\ 
        BC75SOD &  & $\checkmark$ &  &  & $\checkmark$ &  &  &  &  &  \\ 
        36C50SOD &  &  & $\checkmark$ &  &  &  &  &  &  &  \\ 
        36C60SOD &  &  & $\checkmark$  &   &  & $\checkmark$ & $\checkmark$ &  & $\checkmark$  & $\checkmark$ \\ 
        36C75SOD &  &  & $\checkmark$ &  &  &  & $\checkmark$  & $\checkmark$ &  & $\checkmark$  \\ 
        36C80SOD & &  & $\checkmark$ &  &  &  &  &  & $\checkmark$ & $\checkmark$ \\ 
        36C90SOD & &  & $\checkmark$ &  &  &  & $\checkmark$ & $\checkmark$ &  & $\checkmark$ \\ 
        36C100SOD & &  & $\checkmark$ &  &  &  &  & $\checkmark$ &  & $\checkmark$ \\ 
        36C120SOD & &  & $\checkmark$ &  &  &  & $\checkmark$ &  & $\checkmark$ &  \\ 
        \hline
    \end{tabular}   

enter image description here

  • Still have the same problem when using \hline. I'm a big fan of not using vertical lines but this particular table becomes impossible to read without them! – user3079617 Oct 24 '16 at 8:48
  • see my edited example that it works. – user2478 Oct 24 '16 at 8:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.