我需要你的帮助。
我正在用 LaTeX 写论文(我不是非常有经验的用户),我正在附录中插入一些内容。我有一个相当大的复杂横向表格,我想在表格上方放置章节标题(标准方向)。
问题是:我无法让它们都放在同一页上。我知道论坛上还有其他类似的问题,但我都看过了,似乎没有一个是 100% 适合我的。
我附上了代码和问题的图像。
感谢那些花时间回答我的人。
干杯,
尼科
\section{3rd Tests}
\begingroup
\vspace*{\fill}
\begin{landscape}
\begin{table}[p]
\footnotesize
\centering
\resizebox{\columnwidth}{!}{%
\begin{tabular}{cccccc|c|c|c|cc}
\cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textsc{trial} \#} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{drop}\\ \textsc{height}\\ {\textsc{[}}\textsc{cm}{\textsc{]}}\end{tabular}} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{theoretical}\\ \textsc{speed value}\\ $\sqrt{2 \cdot g \cdot \Delta H}$\end{tabular}} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{reference}\\ \textsc{speed value}\\ \textsc{(mocap)}\end{tabular}} & \begin{tabular}[c]{@{}c@{}}\textsc{measured}\\ \textsc{speed value}\\ \textsc{(static camera @}90\textsc{°)}\end{tabular} & \textsc{pe} & \begin{tabular}[c]{@{}c@{}}\textsc{measured}\\ \textsc{speed value}\\ \textsc{(static camera @}45\textsc{°)}\end{tabular} & \textsc{pe} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{measured}\\ \textsc{speed value}\\ \textsc{(panning camera)}\end{tabular}} & \multicolumn{1}{c|}{\textsc{pe}} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{1} & \multicolumn{1}{c|}{100} & \multicolumn{1}{c|}{4.2213} & \multicolumn{1}{c|}{4.3084} & 4.2875 & -0.48 & 4.3117 & 0.07 & \multicolumn{1}{c|}{4.3647} & \multicolumn{1}{c|}{0.88} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{4} & \multicolumn{1}{c|}{150} & \multicolumn{1}{c|}{5.1255} & \multicolumn{1}{c|}{5.1224} & 5.3444 & 4.33 & 4.8522 & -5.27 & \multicolumn{1}{c|}{4.7917} & \multicolumn{1}{c|}{-6.45} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{7} & \multicolumn{1}{c|}{200} & \multicolumn{1}{c|}{6.2538} & \multicolumn{1}{c|}{6.2497} & 6.1934 & -0.9 & 6.6281 & 0.29 & \multicolumn{1}{c|}{6.2739} & \multicolumn{1}{c|}{0.38} \\ \hline
\multicolumn{1}{|c|}{\textbf{\textsc{ape}}} & \multicolumn{5}{c|}{} & \textbf{0.98} & & \textbf{-1.63} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textbf{-1.73}} \\ \hline
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{2} & \multicolumn{1}{c|}{100} & \multicolumn{1}{c|}{4.4731} & \multicolumn{1}{c|}{4.4725} & 4.6564 & 4.11 & 4.3091 & -3.65 & \multicolumn{1}{c|}{4.1525} & \multicolumn{1}{c|}{-7.15} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{5} & \multicolumn{1}{c|}{150} & \multicolumn{1}{c|}{5.2269} & \multicolumn{1}{c|}{5.2162} & 5.3453 & 2.47 & 5.5314 & 6.04 & \multicolumn{1}{c|}{4.6736} & \multicolumn{1}{c|}{-10.4} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{8} & \multicolumn{1}{c|}{200} & \multicolumn{1}{c|}{6.3406} & \multicolumn{1}{c|}{6.2688} & 6.3203 & 0.82 & 6.5222 & 4.04 & \multicolumn{1}{c|}{6.1092} & \multicolumn{1}{c|}{-2.54} \\ \hline
\multicolumn{1}{|c|}{\textbf{\textsc{ape}}} & \multicolumn{5}{c|}{} & \textbf{2.46} & & \textbf{2.14} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textbf{-6.69}} \\ \hline
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{3} & \multicolumn{1}{c|}{100} & \multicolumn{1}{c|}{4.3134} & \multicolumn{1}{c|}{4.2894} & 3.9895 & -6.99 & 4.2653 & -0.56 & \multicolumn{1}{c|}{4.2834} & \multicolumn{1}{c|}{-0.13} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{6} & \multicolumn{1}{c|}{150} & \multicolumn{1}{c|}{5.3054} & \multicolumn{1}{c|}{5.2752} & 5.1954 & -1.52 & 4.8499 & -8.06 & \multicolumn{1}{c|}{4.3366} & \multicolumn{1}{c|}{-17.79} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{9} & \multicolumn{1}{c|}{200} & \multicolumn{1}{c|}{6.3378} & \multicolumn{1}{c|}{6.2622} & 6.1937 & -1.09 & 6.8581 & 9.51 & \multicolumn{1}{c|}{5.8722} & \multicolumn{1}{c|}{-6.22} \\ \hline
\multicolumn{1}{|c|}{\textbf{\textsc{ape}}} & \multicolumn{5}{c|}{} & \textbf{-3.2} & & \textbf{0.29} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textbf{-8.04}} \\ \hline
& & & & & & \textbf{0.08} & & \textbf{0.26} & & \\ \cline{7-7} \cline{9-9}
\end{tabular}%
}
\caption{}
\label{tab:res3}
\end{table}
\end{landscape}
\vspace*{\fill}
\restoregeometry
\endgroup
答案1
如果您将列分隔线缩小一点,重新排列标题并停止使用这么宽的字体,那么它实际上适合纵向显示:
您可以通过将脚注中的“静态相机”文本和试用版中的散列移到新行来节省更多空间。
\documentclass[12pt,a4paper]{article}
\usepackage[left=2.00cm, right=2.00cm, top=2.00cm, bottom=2.00cm]{geometry}
\usepackage{graphicx,lipsum} % added
\usepackage{caption} %for captionof
\begin{document}
\section{3rd Tests}
\begin{minipage}{\textwidth} %
\footnotesize
\centering
\tabcolsep=3pt \let\textsc\textrm %to suppress the smallcaps ...
%\rotatebox{90}
{%
\begin{tabular}{cccccc|c|c|c|cc}
\cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textsc{trial} \#} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{drop}\\ \textsc{height}\\ {\textsc{[}}\textsc{cm}{\textsc{]}}\end{tabular}} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{theoretical}\\ \textsc{speed value}\\ $\sqrt{2 \cdot g \cdot \Delta H}$\end{tabular}} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{reference}\\ \textsc{speed value}\\ \textsc{(mocap)}\end{tabular}} & \begin{tabular}[c]{@{}c@{}}\textsc{measured}\\ \textsc{speed value}\\ static camera\\@90\textsc{°}\end{tabular} & \textsc{pe} & \begin{tabular}[c]{@{}c@{}}\textsc{measured}\\ \textsc{speed value}\\ static camera\\ @45\textsc{°}\end{tabular} & \textsc{pe} & \multicolumn{1}{c|}{\begin{tabular}[c]{@{}c@{}}\textsc{measured}\\ \textsc{speed value}\\ panning\\ camera\end{tabular}} & \multicolumn{1}{c|}{\textsc{pe}} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{1} & \multicolumn{1}{c|}{100} & \multicolumn{1}{c|}{4.2213} & \multicolumn{1}{c|}{4.3084} & 4.2875 & -0.48 & 4.3117 & 0.07 & \multicolumn{1}{c|}{4.3647} & \multicolumn{1}{c|}{0.88} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{4} & \multicolumn{1}{c|}{150} & \multicolumn{1}{c|}{5.1255} & \multicolumn{1}{c|}{5.1224} & 5.3444 & 4.33 & 4.8522 & -5.27 & \multicolumn{1}{c|}{4.7917} & \multicolumn{1}{c|}{-6.45} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{7} & \multicolumn{1}{c|}{200} & \multicolumn{1}{c|}{6.2538} & \multicolumn{1}{c|}{6.2497} & 6.1934 & -0.9 & 6.6281 & 0.29 & \multicolumn{1}{c|}{6.2739} & \multicolumn{1}{c|}{0.38} \\ \hline
\multicolumn{1}{|c|}{\textbf{\textsc{ape}}} & \multicolumn{5}{c|}{} & \textbf{0.98} & & \textbf{-1.63} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textbf{-1.73}} \\ \hline
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{2} & \multicolumn{1}{c|}{100} & \multicolumn{1}{c|}{4.4731} & \multicolumn{1}{c|}{4.4725} & 4.6564 & 4.11 & 4.3091 & -3.65 & \multicolumn{1}{c|}{4.1525} & \multicolumn{1}{c|}{-7.15} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{5} & \multicolumn{1}{c|}{150} & \multicolumn{1}{c|}{5.2269} & \multicolumn{1}{c|}{5.2162} & 5.3453 & 2.47 & 5.5314 & 6.04 & \multicolumn{1}{c|}{4.6736} & \multicolumn{1}{c|}{-10.4} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{8} & \multicolumn{1}{c|}{200} & \multicolumn{1}{c|}{6.3406} & \multicolumn{1}{c|}{6.2688} & 6.3203 & 0.82 & 6.5222 & 4.04 & \multicolumn{1}{c|}{6.1092} & \multicolumn{1}{c|}{-2.54} \\ \hline
\multicolumn{1}{|c|}{\textbf{\textsc{ape}}} & \multicolumn{5}{c|}{} & \textbf{2.46} & & \textbf{2.14} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textbf{-6.69}} \\ \hline
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{3} & \multicolumn{1}{c|}{100} & \multicolumn{1}{c|}{4.3134} & \multicolumn{1}{c|}{4.2894} & 3.9895 & -6.99 & 4.2653 & -0.56 & \multicolumn{1}{c|}{4.2834} & \multicolumn{1}{c|}{-0.13} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{6} & \multicolumn{1}{c|}{150} & \multicolumn{1}{c|}{5.3054} & \multicolumn{1}{c|}{5.2752} & 5.1954 & -1.52 & 4.8499 & -8.06 & \multicolumn{1}{c|}{4.3366} & \multicolumn{1}{c|}{-17.79} \\ \cline{2-11}
\multicolumn{1}{c|}{} & \multicolumn{1}{c|}{9} & \multicolumn{1}{c|}{200} & \multicolumn{1}{c|}{6.3378} & \multicolumn{1}{c|}{6.2622} & 6.1937 & -1.09 & 6.8581 & 9.51 & \multicolumn{1}{c|}{5.8722} & \multicolumn{1}{c|}{-6.22} \\ \hline
\multicolumn{1}{|c|}{\textbf{\textsc{ape}}} & \multicolumn{5}{c|}{} & \textbf{-3.2} & & \textbf{0.29} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{\textbf{-8.04}} \\ \hline
& & & & & & \textbf{0.08} & & \textbf{0.26} & & \\ \cline{7-7} \cline{9-9}
\end{tabular}%
}
\captionof{table}{}
\label{tab:res3}
\end{minipage}
Some text \lipsum
\end{document}
答案2
我根据sideways
环境(来自rotating
包)提出了此解决方案。我借此机会简化了您的代码,删除了所有不必要的 \multicolumn{1}{c|}{…}。
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[a4paper, showframe]{geometry}
\usepackage{array, makecell, caption}
\usepackage{rotating}
\begin{document}
\section{3rd Tests}%e
\vspace*{-4ex}
\begin{sideways}
\parbox{\textheight}{\small
\renewcommand{\theadfont}{\small\scshape}
\setlength{\tabcolsep}{4pt}
\centering
\begin{tabular}{*{10}{|c}|}
\cline{1-10}
\thead{trial\\ \#} & \thead{drop\\height\\ {[cm]}} & \thead{theoretical \\ speed value \\ $\sqrt{2 \cdot g \cdot \Delta H\mathstrut}$ } & \thead{reference \\ speed value\\ (mocap)} & \thead{measured \\ speed value \\(static camera\\ @90°)} & \thead{pe} & \thead{measured \\ speed value \\ (static camera \\ @ 45°)} & \thead{pe} & \thead{measured \\ speed value \\ (panning camera)} & \thead{pe}\\ \cline{1-10}
1 & 100 & 4.2213 & 4.3084 & 4.2875 & -0.48 & 4.3117 & 0.07 & 4.3647 & 0.88 \\ \cline{1-10}
4 & 150 & 5.1255 & 5.1224 & 5.3444 & 4.33 & 4.8522 & -5.27 & 4.7917 & -6.45 \\ \cline{1-10}
7 & 200 & 6.2538 & 6.2497 & 6.1934 & -0.9 & 6.6281 & 0.29 & 6.2739 & 0.38 \\ \hline
\multicolumn{5}{l|}{\bfseries\scshape\llap{ape\enspace }} & \textbf{0.98} & & \textbf{-1.63} & & \textbf{-1.73} \\ \hline
2 & 100 & 4.4731 & 4.4725 & 4.6564 & 4.11 & 4.3091 & -3.65 & 4.1525 & -7.15 \\ \cline{1-10}
5 & 150 & 5.2269 & 5.2162 & 5.3453 & 2.47 & 5.5314 & 6.04 & 4.6736 & -10.4 \\ \cline{1-10}
8 & 200 & 6.3406 & 6.2688 & 6.3203 & 0.82 & 6.5222 & 4.04 & 6.1092 & -2.54 \\ \hline
\multicolumn{5}{l|}{\bfseries\scshape\llap{ape\enspace }} & \textbf{2.46} & & \textbf{2.14} & & \textbf{-6.69} \\ \hline
3 & 100 & 4.3134 & 4.2894 & 3.9895 & -6.99 & 4.2653 & -0.56 & 4.2834 & -0.13 \\ \cline{1-10}
6 & 150 & 5.3054 & 5.2752 & 5.1954 & -1.52 & 4.8499 & -8.06 & 4.3366 & -17.79 \\ \cline{1-10}
9 & 200 & 6.3378 & 6.2622 & 6.1937 & -1.09 & 6.8581 & 9.51 & 5.8722 & -6.22 \\ \hline
\multicolumn{5}{l|}{\bfseries\scshape\llap{ape\enspace }} & \textbf{-3.2} & & \textbf{0.29} & & \textbf{-8.04} \\ \hline
\multicolumn{4}{c|}{} & \textbf{0.08} & & \textbf{0.26} & \multicolumn{2}{c}{} \\ \cline{5-5} \cline{7-7}
\end{tabular}%
\leavevmode
\captionof{table}{}
\label{tab:res3}}
\end{sideways}
\end{document}