Skip to content

Instantly share code, notes, and snippets.

@rischanlab
Last active November 24, 2021 08:35
Show Gist options
  • Save rischanlab/36ac077e80a698e6acb2 to your computer and use it in GitHub Desktop.
Save rischanlab/36ac077e80a698e6acb2 to your computer and use it in GitHub Desktop.
Sub Table in Latex
%Rischan Mafrur
%Sub Table in Latex
% May 20, 2014
\begin{table}[h]
\begin{subtable}[h]{0.16\textwidth}
\centering
\begin{tabular}{|l|l|}
XXX & YYY\\
\hline
value X & value Y\\
\end{tabular}
\caption{Caption Subtable A}
\label{tab:label subtable A}
\end{subtable}
\hfill
\begin{subtable}[h]{0.15\textwidth}
\centering
\begin{tabular}{|l|l|}
XXX & YYY\\
\hline
value X & value Y\\
\end{tabular}
\caption{Caption Sub Table B}
\label{tab:label subtable B}
\end{subtable}
\hfill
\begin{subtable}[h]{0.16\textwidth}
\centering
\begin{tabular}{|l|l|}
XXX & YYY\\
\hline
value X & value Y\\
\end{tabular}
\caption{Caption SubTable C}
\label{tab:label subtable C}
\end{subtable}
\caption{Caption Main/ All Table}
\label{tab:label all table}
\end{table}
@pfandzelter
Copy link

If you want to use the subfigure environment, you will have to use \usepackage{subcaption}.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment