2개의 테이블을 나란히 표시하는 방법은 무엇입니까?

2개의 테이블을 나란히 표시하는 방법은 무엇입니까?

세 개의 테이블이 있는 문서가 있습니다. 현재 이 세 개의 테이블은 페이지에 비해 너무 길기 때문에 두 개의 테이블을 나란히 표시하고 그 아래에 세 번째 테이블을 표시하고 싶습니다. 이렇게 하면 모든 테이블이 동일한 페이지에 들어갈 수 있습니다.

이것은 내 MWE입니다.

\documentclass[a4paper,10pt]{article}
\usepackage[utf8]{inputenc}
\usepackage{microtype}
\usepackage[margin=2.54cm]{geometry}
\usepackage{graphicx,booktabs,tabularx}
\usepackage[table]{xcolor}
\usepackage{array}

%define some nice colors
\definecolor{middleware_green}{RGB}{82, 119, 17}
\definecolor{middleware_white}{RGB}{255, 255, 255}
\definecolor{middleware_light_gray}{RGB}{239, 239, 239}
\definecolor{middleware_dark_gray}{RGB}{153, 153, 153}

\renewcommand{\tabularxcolumn}[1]{>{\small}m{#1}}
\newcolumntype{L}{>{\leavevmode\ignorespaces\raggedleft\arraybackslash\sffamily}X}%
\newcolumntype{C}{>{\leavevmode\ignorespaces\centering\arraybackslash\sffamily}X}%
\rowcolors{2}{middleware_white}{middleware_light_gray}

\begin{document}

\begin{table}[htbp]

\begin{tabularx}{0.45\textwidth}{|L|L|L|L|}
\hline\rowcolor{middleware_green}
\multicolumn{ 4}{|c|}{\textcolor{white}{\textbf{1 Source, 1 Session, 1 Client, Exp0}}} \\ \hline
\rowcolor{middleware_dark_gray}
\multicolumn{1}{|C}{\footnotesize\textcolor{white}{\textbf{Mes\-sa\-ges per mi\-nu\-te per sour\-ce}}} & 
\multicolumn{1}{|C}{\footnotesize\centering\textcolor{white}{\textbf{Mid\-dle\-ware Exec. Ti\-me (s)}}} & 
\multicolumn{1}{|C}{\footnotesize\centering\textcolor{white}{\textbf{De\-lay (s)}}} & 
\multicolumn{1}{|C|}{\footnotesize\textcolor{white}{\textbf{Ave\-ra\-ge De\-lay (s)}}} \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
60 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 &  \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
120 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 &  \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
240 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 & \\ \hline
 & 69 & 9 &  \\ \cline{ 2- 3}
480 & 69 & 9 & 16.67 \\ \cline{ 2- 3}
 & 92 & 32 &  \\ \hline
 & 159 & 99 &  \\ \cline{ 2- 3}
1000 & 173 & 113 & 109.67 \\ \cline{ 2- 3}
 & 177 & 117 &  \\ \hline
 & 391 & 331 &  \\ \cline{ 2- 3}
2000 & 383 & 323 & 311.00 \\ \cline{ 2- 3}
 & 339 & 279 &  \\ \hline
 & 561 & 501 & \\ \cline{ 2- 3}
4000 & 631 & 501 & 512.33 \\ \cline{ 2- 3}
 & 595 & 535 &  \\ \hline
\end{tabularx}


\begin{tabularx}{0.45\textwidth}{|L|L|L|L|}
\hline\rowcolor{middleware_green}
\multicolumn{ 4}{|c|}{\textcolor{white}{\textbf{1 Source, 1 Session, 1 Client, Exp0}}} \\ \hline
\rowcolor{middleware_dark_gray}
\multicolumn{1}{|C}{\footnotesize\textcolor{white}{\textbf{Mes\-sa\-ges per mi\-nu\-te per sour\-ce}}} & 
\multicolumn{1}{|C}{\footnotesize\centering\textcolor{white}{\textbf{Mid\-dle\-ware Exec. Ti\-me (s)}}} & 
\multicolumn{1}{|C}{\footnotesize\centering\textcolor{white}{\textbf{De\-lay (s)}}} & 
\multicolumn{1}{|C|}{\footnotesize\textcolor{white}{\textbf{Ave\-ra\-ge De\-lay (s)}}} \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
60 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 &  \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
120 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 &  \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
240 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 & \\ \hline
 & 69 & 9 &  \\ \cline{ 2- 3}
480 & 69 & 9 & 16.67 \\ \cline{ 2- 3}
 & 92 & 32 &  \\ \hline
 & 159 & 99 &  \\ \cline{ 2- 3}
1000 & 173 & 113 & 109.67 \\ \cline{ 2- 3}
 & 177 & 117 &  \\ \hline
 & 391 & 331 &  \\ \cline{ 2- 3}
2000 & 383 & 323 & 311.00 \\ \cline{ 2- 3}
 & 339 & 279 &  \\ \hline
 & 561 & 501 & \\ \cline{ 2- 3}
4000 & 631 & 501 & 512.33 \\ \cline{ 2- 3}
 & 595 & 535 &  \\ \hline
\end{tabularx}

\begin{tabularx}{0.45\textwidth}{|L|L|L|L|}
\hline\rowcolor{middleware_green}
\multicolumn{ 4}{|c|}{\textcolor{white}{\textbf{1 Source, 1 Session, 1 Client, Exp0}}} \\ \hline
\rowcolor{middleware_dark_gray}
\multicolumn{1}{|C}{\footnotesize\textcolor{white}{\textbf{Mes\-sa\-ges per mi\-nu\-te per sour\-ce}}} & 
\multicolumn{1}{|C}{\footnotesize\centering\textcolor{white}{\textbf{Mid\-dle\-ware Exec. Ti\-me (s)}}} & 
\multicolumn{1}{|C}{\footnotesize\centering\textcolor{white}{\textbf{De\-lay (s)}}} & 
\multicolumn{1}{|C|}{\footnotesize\textcolor{white}{\textbf{Ave\-ra\-ge De\-lay (s)}}} \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
60 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 &  \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
120 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 &  \\ \hline
 & 60 & 0 &  \\ \cline{ 2- 3}
240 & 60 & 0 & 0.00 \\ \cline{ 2- 3}
 & 60 & 0 & \\ \hline
 & 69 & 9 &  \\ \cline{ 2- 3}
480 & 69 & 9 & 16.67 \\ \cline{ 2- 3}
 & 92 & 32 &  \\ \hline
 & 159 & 99 &  \\ \cline{ 2- 3}
1000 & 173 & 113 & 109.67 \\ \cline{ 2- 3}
 & 177 & 117 &  \\ \hline
 & 391 & 331 &  \\ \cline{ 2- 3}
2000 & 383 & 323 & 311.00 \\ \cline{ 2- 3}
 & 339 & 279 &  \\ \hline
 & 561 & 501 & \\ \cline{ 2- 3}
4000 & 631 & 501 & 512.33 \\ \cline{ 2- 3}
 & 595 & 535 &  \\ \hline
\end{tabularx}

\label{tables_test}
\caption{three tables!}
\end{table}


\end{document}

어떻게 이를 달성할 수 있나요? 이 세 개의 테이블을 한 페이지에 맞추려면 어떻게 해야 합니까?

답변1

표 형식 환경은 문자와 동일한 규칙을 사용하여 배치됩니다. 예를 들어 X각각 사이에 단락 구분(빈 줄)이 있으므로 세로 간격만 지정됩니다.

관련 정보