To merge columns: \multicolumn{cell count}{layout}{content}
To merge rows: \multirow{cell count}{layout}{content}
Example:
\hline
& underlines current table row \\ \hline
l
& left \\
\verb|c|
& center\\
\verb|r|
& right\\
\verb|p{'width'}|
& custom width, aligned top \\
\verb|m{'width'}|
& custom width, aligned middle \\
\verb|b{'width'}|
& custom width, aligned bottom \\ \hline
\verb,|,
& single, as in \verb,l|,
\\
\verb,||,
& double, as in \verb,l||c,
\\ \hline
\verb|\\|
& new table row \\
\verb|newline|
& new line within cell \\
Table cheat sheet | ||
---|---|---|
Horizontal line | \hline |
underlines current table row |
Column types | l |
left |
c |
center | |
r |
right | |
p{'width'} |
custom width, aligned top | |
m{'width'} |
custom width, aligned middle11requires array.sty | |
b{'width'} |
custom width, aligned bottom22requires array.sty | |
Borders | none | default |
| |
single, as in l| | |
|| |
double, as in l||c | |
Alignment | & | separates columns |
End of line | \\ |
new table row |
newline |
new line within cell |