0

I've been trying to get a midrule line under Passing, but can't seem to get it to work. I've gotten it in the two other spots, but cannot figure out why it won't let me on this one.

\begin{table}
\centering
\begin{tabular}{l*{6}{c}}
\toprule
\multicolumn{3}{c}{Sieve Size}  & \multicolumn{2}{c}{Retaining} & 
\multicolumn{1}{c}{Passing}  \\
\cmidrule(r){1-3}\cmidrule(r){4-5}
\multicolumn{1}{c}{US} & \multicolumn{1}{c}{in.} &  \multicolumn{1}{c} 
{mm.}&\multicolumn{1}{c}{\%} & \multicolumn{1}{c}{Cum. \%} &\multicolumn{1}{c} 
{\%}\\\midrule
$\frac{3}{8}$ & 0.5 & 12.5 & 4.2 & 4.2 & 95.8  \\ 
\#4 & 0.1870 & 4.75 & 23.7 & 27.9 & 72.1\\ 
\#8 & 0.0937 & 2.36 & 20.0 & 47.9 & 52.1 \\ 
\#16 & 0.0460 & 1.18 & 28.1 & 76.0 & 24.0\\
\#30 & 0.0240 & 0.60 & 7.1 & 83.1 & 16.9 \\
\#50 & 0.0120 & 0.30 & 8.4 & 91.5 & 8.5\\
\#100 & 0.0060 & 0.15 & 6.8 & 98.3 & 1.7 \\
Pan & -- & -- & 1.7 & 100 & 0 \\\midrule
Sum & & &100 & 528.9 & 271.0\\ \bottomrule
  \end{tabular}
\end{table}
5
  • You only have cmidrule from 1-5. Need under 6, too.
    – AML
    Commented Jun 11, 2018 at 0:01
  • I was trying and that would just cause an error to show up. Commented Jun 11, 2018 at 0:04
  • 2
    Did you try \cmidrule(l){6-6}?
    – Mico
    Commented Jun 11, 2018 at 0:06
  • Welcome! Please don't post fragments of code, but complete minimal examples. Which error? What code can we use to reproduce it?
    – cfr
    Commented Jun 11, 2018 at 0:11
  • That worked, I was way overthinking that! Thank you!! Commented Jun 11, 2018 at 0:12

1 Answer 1

1

You are missing \cmidrule{6-6}

\begin{table}
\centering
\begin{tabular}{l*{6}{c}}
\toprule
\multicolumn{3}{c}{Sieve Size}  & \multicolumn{2}{c}{Retaining} & 
\multicolumn{1}{c}{Passing}  \\
\cmidrule(r){1-3}\cmidrule(r){4-5}\cmidrule{6-6}
\multicolumn{1}{c}{US} & \multicolumn{1}{c}{in.} &  \multicolumn{1}{c} 
{mm.}&\multicolumn{1}{c}{\%} & \multicolumn{1}{c}{Cum. \%} &\multicolumn{1}{c} 
{\%}\\\midrule
$\frac{3}{8}$ & 0.5 & 12.5 & 4.2 & 4.2 & 95.8  \\ 
\#4 & 0.1870 & 4.75 & 23.7 & 27.9 & 72.1\\ 
\#8 & 0.0937 & 2.36 & 20.0 & 47.9 & 52.1 \\ 
\#16 & 0.0460 & 1.18 & 28.1 & 76.0 & 24.0\\
\#30 & 0.0240 & 0.60 & 7.1 & 83.1 & 16.9 \\
\#50 & 0.0120 & 0.30 & 8.4 & 91.5 & 8.5\\
\#100 & 0.0060 & 0.15 & 6.8 & 98.3 & 1.7 \\
Pan & -- & -- & 1.7 & 100 & 0 \\\midrule
Sum & & &100 & 528.9 & 271.0\\ \bottomrule
  \end{tabular}
\end{table}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .