将列添加到现有多行 Table
Adding Column to Existing Multirow Table
我想要做的是在下面的 table 中添加第一列。这个新列的标题为 "Element",并且只有三行("Upper Level" 列中每两行一行)标题为 "Argon"、"Krypton" 和 "Xenon".
我相信这会使 table 更好,但我对 \multirow 和 \multicolumn 还是陌生的,所以我无法调整一些东西来完成这项工作。请查看下面的代码和生成的图像 table。
如果您需要任何说明,请告诉我。
\begin{table}[t!]
\caption{Comparing experiment to literature for branching ratios of two strongest transitions to metastable state for Ar, Kr and Xe.}
\centering
\begin{tabular}{|c|c|c|c|c|c|c|}
\hline
\textbf{Upper Level}
& \textbf{Lower Level}
& \textbf{$\mathbf{\lambda_{ij}}$ (nm)}
& \textbf{$\mathbf{A_{ij} (10^{7} s^{-1})}$}
& \textbf{$\mathbf{\beta_{exp}}$ (\%)}
& \textbf{$\mathbf{\beta_{th}}$ (\%)}
& \textbf{$\mathbf{\beta_{rec}}$ (\%)}
\
\hline
\multirow{3}[8]{1in}{\centering Ar - 2p$^{6}$ (2$\times8\,nm)}
& 1s$_{2}$ & 922.5 & 0.59-0.63 & 16 & 16 & 26 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 800.6 & 0.48-0.51 & 13 & 12 & 25 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 763.5 & 2.62-2.96 & 71 & 72 & 49 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Ar - 2p$^{8}$ (2$\times8\,nm)}
& 1s$_{2}$ & 978.5 & 0.11-0.17 & 3 & 5 & 7 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 842.5 & 2.11-2.52 & 66 & 67 & 51 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 801.5 & 1.00-1.04 & 31 & 28 & 43 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Kr - 2p$^{6}$ (2$\times5\,nm)}
& 1s$_{2}$ & 1373.9 & 0.02-0.03 & 0 & 1 & 7 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 819.0 & 0.9-1.1 & 26 & 24 & 22 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 760.2 & 2.6-3.1 & 74 & 75 & 71 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Kr - 2p$^{8}$ (2$\times7\,nm)}
& 1s$_{2}$ & 1547.4 & 0.003-0.008 & 0 & 0 & 1 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 877.7 & 1.5-2.6 & 68 & 68 & 69 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 810.4 & 0.7-1.1 & 32 & 32 & 30 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Xe - 2p$^{6}$ (2$\times2\,nm)}
& 1s$_{2}$ & 4932.4 & 0.002 & 0 & 0 & 0 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 895.5 & 1.06 & 21 & 30 & 9 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 823.4 & 2.49 & 79 & 70 & 91 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Xe - 2p$^{9}$ (2$\times6\,nm)}
& 1s$_{2}$ & 10698.1 & 0 & 0 & 0 & 0 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 992.6 & 1.96 & 49 & 65 & 71 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 904.8 & 1.07 & 51 & 35 & 29 \bigstrut\
\hline
\end{tabular}
\label{tbl:choosingTransition}
\end{table}
Table此时
这是一个可能的解决方案。它使用沿行生成的旋转 parbox。
\documentclass{article}
\usepackage{array,multirow,graphicx}
\usepackage{bigstrut}
\begin{document}
\newcommand{\rotatemultirow}[1]{\parbox[t]{2mm}{\multirow{6}{*}{\rotatebox[origin=l]{90}{#1}}}}
\begin{table}[t!]
\caption{Comparing experiment to literature for branching ratios of two strongest transitions to metastable state for Ar, Kr and Xe.}
\centering
\begin{tabular}{|c|c|c|c|c|c|c|c|}
\cline{2-8}
\multicolumn{1}{c|}{}
&\textbf{Upper Level}
& \textbf{Lower Level}
& \textbf{$\mathbf{\lambda_{ij}}$ (nm)}
& \textbf{$\mathbf{A_{ij} (10^{7} s^{-1})}$}
& \textbf{$\mathbf{\beta_{exp}}$ (\%)}
& \textbf{$\mathbf{\beta_{th}}$ (\%)}
& \textbf{$\mathbf{\beta_{rec}}$ (\%)}
\
\hline
\rotatemultirow{Argon\hspace{1cm}}
&\multirow{3}[8]{1in}{\centering Ar - 2p$^{6}$ (2$\times8\,nm)}
& 1s$_{2}$ & 922.5 & 0.59-0.63 & 16 & 16 & 26 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 800.6 & 0.48-0.51 & 13 & 12 & 25 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 763.5 & 2.62-2.96 & 71 & 72 & 49 \bigstrut\
\cline{2-8}
& \multirow{3}[8]{1in}{\centering Ar - 2p$^{8}$ (2$\times8\,nm)}
& 1s$_{2}$ & 978.5 & 0.11-0.17 & 3 & 5 & 7 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 842.5 & 2.11-2.52 & 66 & 67 & 51 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 801.5 & 1.00-1.04 & 31 & 28 & 43 \bigstrut\
\hline
\rotatemultirow{Krypton\hspace{1cm}}
&\multirow{3}[8]{1in}{\centering Kr - 2p$^{6}$ (2$\times5\,nm)}
& 1s$_{2}$ & 1373.9 & 0.02-0.03 & 0 & 1 & 7 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 819.0 & 0.9-1.1 & 26 & 24 & 22 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 760.2 & 2.6-3.1 & 74 & 75 & 71 \bigstrut\
\cline{2-8}
&\multirow{3}[8]{1in}{\centering Kr - 2p$^{8}$ (2$\times7\,nm)}
& 1s$_{2}$ & 1547.4 & 0.003-0.008 & 0 & 0 & 1 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 877.7 & 1.5-2.6 & 68 & 68 & 69 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 810.4 & 0.7-1.1 & 32 & 32 & 30 \bigstrut\
\hline
\rotatemultirow{Xenon\hspace{1cm}}
&\multirow{3}[8]{1in}{\centering Xe - 2p$^{6}$ (2$\times2\,nm)}
& 1s$_{2}$ & 4932.4 & 0.002 & 0 & 0 & 0 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 895.5 & 1.06 & 21 & 30 & 9 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 823.4 & 2.49 & 79 & 70 & 91 \bigstrut\
\cline{2-8}
&\multirow{3}[8]{1in}{\centering Xe - 2p$^{9}$ (2$\times6\,nm)}
& 1s$_{2}$ & 10698.1 & 0 & 0 & 0 & 0 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 992.6 & 1.96 & 49 & 65 & 71 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 904.8 & 1.07 & 51 & 35 & 29 \bigstrut\
\hline
\end{tabular}
\label{tbl:choosingTransition}
\end{table}
\end{document}
不幸的是,我没有成功自动将名字垂直居中,我用了一个hspace
来微调它们的垂直位置。
我想要做的是在下面的 table 中添加第一列。这个新列的标题为 "Element",并且只有三行("Upper Level" 列中每两行一行)标题为 "Argon"、"Krypton" 和 "Xenon".
我相信这会使 table 更好,但我对 \multirow 和 \multicolumn 还是陌生的,所以我无法调整一些东西来完成这项工作。请查看下面的代码和生成的图像 table。
如果您需要任何说明,请告诉我。
\begin{table}[t!]
\caption{Comparing experiment to literature for branching ratios of two strongest transitions to metastable state for Ar, Kr and Xe.}
\centering
\begin{tabular}{|c|c|c|c|c|c|c|}
\hline
\textbf{Upper Level}
& \textbf{Lower Level}
& \textbf{$\mathbf{\lambda_{ij}}$ (nm)}
& \textbf{$\mathbf{A_{ij} (10^{7} s^{-1})}$}
& \textbf{$\mathbf{\beta_{exp}}$ (\%)}
& \textbf{$\mathbf{\beta_{th}}$ (\%)}
& \textbf{$\mathbf{\beta_{rec}}$ (\%)}
\
\hline
\multirow{3}[8]{1in}{\centering Ar - 2p$^{6}$ (2$\times8\,nm)}
& 1s$_{2}$ & 922.5 & 0.59-0.63 & 16 & 16 & 26 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 800.6 & 0.48-0.51 & 13 & 12 & 25 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 763.5 & 2.62-2.96 & 71 & 72 & 49 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Ar - 2p$^{8}$ (2$\times8\,nm)}
& 1s$_{2}$ & 978.5 & 0.11-0.17 & 3 & 5 & 7 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 842.5 & 2.11-2.52 & 66 & 67 & 51 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 801.5 & 1.00-1.04 & 31 & 28 & 43 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Kr - 2p$^{6}$ (2$\times5\,nm)}
& 1s$_{2}$ & 1373.9 & 0.02-0.03 & 0 & 1 & 7 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 819.0 & 0.9-1.1 & 26 & 24 & 22 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 760.2 & 2.6-3.1 & 74 & 75 & 71 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Kr - 2p$^{8}$ (2$\times7\,nm)}
& 1s$_{2}$ & 1547.4 & 0.003-0.008 & 0 & 0 & 1 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 877.7 & 1.5-2.6 & 68 & 68 & 69 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 810.4 & 0.7-1.1 & 32 & 32 & 30 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Xe - 2p$^{6}$ (2$\times2\,nm)}
& 1s$_{2}$ & 4932.4 & 0.002 & 0 & 0 & 0 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 895.5 & 1.06 & 21 & 30 & 9 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 823.4 & 2.49 & 79 & 70 & 91 \bigstrut\
\hline
\multirow{3}[8]{1in}{\centering Xe - 2p$^{9}$ (2$\times6\,nm)}
& 1s$_{2}$ & 10698.1 & 0 & 0 & 0 & 0 \bigstrut\\cline{2-7}
& 1s$_{4}$ & 992.6 & 1.96 & 49 & 65 & 71 \bigstrut\\cline{2-7}
& 1s$_{5}$ & 904.8 & 1.07 & 51 & 35 & 29 \bigstrut\
\hline
\end{tabular}
\label{tbl:choosingTransition}
\end{table}
Table此时
这是一个可能的解决方案。它使用沿行生成的旋转 parbox。
\documentclass{article}
\usepackage{array,multirow,graphicx}
\usepackage{bigstrut}
\begin{document}
\newcommand{\rotatemultirow}[1]{\parbox[t]{2mm}{\multirow{6}{*}{\rotatebox[origin=l]{90}{#1}}}}
\begin{table}[t!]
\caption{Comparing experiment to literature for branching ratios of two strongest transitions to metastable state for Ar, Kr and Xe.}
\centering
\begin{tabular}{|c|c|c|c|c|c|c|c|}
\cline{2-8}
\multicolumn{1}{c|}{}
&\textbf{Upper Level}
& \textbf{Lower Level}
& \textbf{$\mathbf{\lambda_{ij}}$ (nm)}
& \textbf{$\mathbf{A_{ij} (10^{7} s^{-1})}$}
& \textbf{$\mathbf{\beta_{exp}}$ (\%)}
& \textbf{$\mathbf{\beta_{th}}$ (\%)}
& \textbf{$\mathbf{\beta_{rec}}$ (\%)}
\
\hline
\rotatemultirow{Argon\hspace{1cm}}
&\multirow{3}[8]{1in}{\centering Ar - 2p$^{6}$ (2$\times8\,nm)}
& 1s$_{2}$ & 922.5 & 0.59-0.63 & 16 & 16 & 26 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 800.6 & 0.48-0.51 & 13 & 12 & 25 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 763.5 & 2.62-2.96 & 71 & 72 & 49 \bigstrut\
\cline{2-8}
& \multirow{3}[8]{1in}{\centering Ar - 2p$^{8}$ (2$\times8\,nm)}
& 1s$_{2}$ & 978.5 & 0.11-0.17 & 3 & 5 & 7 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 842.5 & 2.11-2.52 & 66 & 67 & 51 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 801.5 & 1.00-1.04 & 31 & 28 & 43 \bigstrut\
\hline
\rotatemultirow{Krypton\hspace{1cm}}
&\multirow{3}[8]{1in}{\centering Kr - 2p$^{6}$ (2$\times5\,nm)}
& 1s$_{2}$ & 1373.9 & 0.02-0.03 & 0 & 1 & 7 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 819.0 & 0.9-1.1 & 26 & 24 & 22 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 760.2 & 2.6-3.1 & 74 & 75 & 71 \bigstrut\
\cline{2-8}
&\multirow{3}[8]{1in}{\centering Kr - 2p$^{8}$ (2$\times7\,nm)}
& 1s$_{2}$ & 1547.4 & 0.003-0.008 & 0 & 0 & 1 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 877.7 & 1.5-2.6 & 68 & 68 & 69 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 810.4 & 0.7-1.1 & 32 & 32 & 30 \bigstrut\
\hline
\rotatemultirow{Xenon\hspace{1cm}}
&\multirow{3}[8]{1in}{\centering Xe - 2p$^{6}$ (2$\times2\,nm)}
& 1s$_{2}$ & 4932.4 & 0.002 & 0 & 0 & 0 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 895.5 & 1.06 & 21 & 30 & 9 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 823.4 & 2.49 & 79 & 70 & 91 \bigstrut\
\cline{2-8}
&\multirow{3}[8]{1in}{\centering Xe - 2p$^{9}$ (2$\times6\,nm)}
& 1s$_{2}$ & 10698.1 & 0 & 0 & 0 & 0 \bigstrut\\cline{3-8}
& & 1s$_{4}$ & 992.6 & 1.96 & 49 & 65 & 71 \bigstrut\\cline{3-8}
& & 1s$_{5}$ & 904.8 & 1.07 & 51 & 35 & 29 \bigstrut\
\hline
\end{tabular}
\label{tbl:choosingTransition}
\end{table}
\end{document}
不幸的是,我没有成功自动将名字垂直居中,我用了一个hspace
来微调它们的垂直位置。