Do you know how can I set the following tables in LaTeX? (Just the first two lines are enough)
-
1Can you give us a MWE to start with?– samcarter_is_at_topanswers.xyzJun 13, 2016 at 15:35
-
You already accept one answer to your original question. If you now faced with new problem, than will be better to ask new question than edit old one. In it you can make link to this question and also clearly emphasize what is your new problem.– ZarkoJun 14, 2016 at 21:54
3 Answers
I would suggest multicolumn
and cline
.
\begin{tabular}{ccccc}
& & \multicolumn{2}{c}{well} & \tabularnewline
\cline{3-4}
& & 1 & 2 & 3\tabularnewline
\hline
some & a & b & c & d\tabularnewline
\hline
stuff & e & f & g & h\tabularnewline
\hline
in & i & j & k & l\tabularnewline
\hline
a & m & n & o & p\tabularnewline
\end{tabular}
Below existing links will help your request:
I used the same code. But I changed the following lines and compiled.
\begin{tabularx}{\textwidth}{lrcp{2.8cm}p{2.5cm}}
\toprule
& \multicolumn{2}{l}{Proportions (\% )} & \multicolumn{2}{l}{ }\\
& \multicolumn{2}{l}{if not indicated otherwise}&\multicolumn{2}{l}{ OR (95\% Cl)for group differences}\\
\cmidrule{2-5}
& Type 1 & & & \\
Outcome variable&diabetes &Control&Crude&Adjusted \tabularnewline
\midrule
I got the following