![创建适合双列样式页面的一列的表格](https://linux22.com/image/291428/%E5%88%9B%E5%BB%BA%E9%80%82%E5%90%88%E5%8F%8C%E5%88%97%E6%A0%B7%E5%BC%8F%E9%A1%B5%E9%9D%A2%E7%9A%84%E4%B8%80%E5%88%97%E7%9A%84%E8%A1%A8%E6%A0%BC.png)
我想在双列样式页面 (IEEEtran) 中创建一个表格,但我希望表格只适合其中一列。我制作的表格超出了页面的单列宽度。请帮忙。这是表格
\documentclass[11pt,twocolumn,conference]{IEEEtran}
.
.
.
\begin{table}[h]
\caption{hello2 testing}
\label{1234}
\begin{tabular}{cccccc}
& LfdR & KLSRf & MLDFSP & PNDND & LDFSSVM \\
Aa & 97.8+-2.3 & 97.4+-3.0 & 97.4+-3.0 & 97.0+-3.6 & 99.1+-1.8 \\
Al & 69.8+-9.5 & 93.6+-3.6 & 86.9+-8.4 & 91.5+-4.5 & 94.9+-5.4 \\
Av & 97.0+-2.9 & 99.2+-1.8 & 99.6+-1.4 & 98.3+-2.9 & 99.6+-1.4 \\
Aw & 97.8+-3.1 & 95.3+-3.1 & 96.2+-2.5 & 92.4+-3.3 & 97.5+-3.0 \\
Ay & 77.5+-7.2 & 90.2+-4.1 & 90.2+-5.7 & 88.1+-4.8 & 91.6+-4.9 \\
avg & 88.0 & 95.1 & 94.1 & 93.5 & 96.5
\end{tabular}
\end{table}
答案1
也许这就是你所追求的:
\documentclass[11pt,twocolumn,conference]{IEEEtran}
\usepackage{amsmath,array,graphicx}
\usepackage{kantlipsum}
\begin{document}
\kant[1-2]
\begin{table}[htb]
\caption{hello2 testing}
\label{1234}
\resizebox{\columnwidth}{!}{%
\begin{tabular}{c*{5}{>{$}c<{$}}}
& \text{LfdR} & \text{KLSRf} & \text{MLDFSP} & \text{PNDND} & \text{LDFSSVM} \\
Aa & 97.8\pm 2.3 & 97.4\pm 3.0 & 97.4\pm 3.0 & 97.0\pm 3.6 & 99.1\pm 1.8 \\
Al & 69.8\pm 9.5 & 93.6\pm 3.6 & 86.9\pm 8.4 & 91.5\pm 4.5 & 94.9\pm 5.4 \\
Av & 97.0\pm 2.9 & 99.2\pm 1.8 & 99.6\pm 1.4 & 98.3\pm 2.9 & 99.6\pm 1.4 \\
Aw & 97.8\pm 3.1 & 95.3\pm 3.1 & 96.2\pm 2.5 & 92.4\pm 3.3 & 97.5\pm 3.0 \\
Ay & 77.5\pm 7.2 & 90.2\pm 4.1 & 90.2\pm 5.7 & 88.1\pm 4.8 & 91.6\pm 4.9 \\
avg & 88.0 & 95.1 & 94.1 & 93.5 & 96.5
\end{tabular}
}
\end{table}
\kant[3-5]
\end{document}
我已使用\resizebox
包graphicx
ti 重新调整表格大小以适合列内。此外,我已将+-
中的所有内容替换为\pm
。