抱歉打扰大家了!我有一个关于竖点的问题,一般我现在都是用\vdot
在表格中来表示省略,但是我想让它们集中起来表示省略,目前的代码如下:
\documentclass{article}
\usepackage{amssymb} % Add
\usepackage{bbding} % Add
\usepackage[export]{adjustbox}
\usepackage{array}
\usepackage{tabularx}
\usepackage{booktabs}
\usepackage{graphicx}
\usepackage{cellspace}
\def\tabularxcolumn#1{m{#1}}
\begin{document}
\begin{table*}[htbp]
\caption{Text.}
\begin{tabularx}{\textwidth}{ l Sl X }
\toprule
Iterations & Samples & Comments \\
\midrule
0 & \includegraphics[width=.6\textwidth,valign=M]{000000.png} & Text is always being here\\
32 & \includegraphics[width=.6\textwidth,valign=M]{000000.png} & Text \\
64 & \includegraphics[width=.6\textwidth,valign=M]{000000.png} & Text \\
128 & \includegraphics[width=.6\textwidth,valign=M]{000000.png} & Text \\
192 & \includegraphics[width=.6\textwidth,valign=M]{000000.png} & Text \\
\vdots & \vdots & \vdots \\
3200 & \includegraphics[width=.6\textwidth,valign=M]{000000.png} & Text \\
\bottomrule
\end{tabularx}
\label{tab4}
\end{table*}
\end{document}
请保持行与行之间的间隙,除九个点外,其余所有点左对齐。提前感谢大家!
答案1
改编
- 用于
example-image
最小工作示例(MWE)height=20mm
仅为该示例图像添加选项
- 用于
\multicolumn{1}{c}{\vdots}
将单个单元格居中对齐(参见在表格环境中对齐特定单元格) - 表格中的数字应该右对齐(更好的样式)
代码
\documentclass{article}
\usepackage{amssymb} % Add
\usepackage{bbding} % Add
\usepackage[export]{adjustbox}
\usepackage{array}
\usepackage{tabularx}
\usepackage{booktabs}
\usepackage{graphicx}
\usepackage{cellspace}
\def\tabularxcolumn#1{m{#1}}
\begin{document}
\begin{table*}[htbp]
\caption{Text.}
\begin{tabularx}{\textwidth}{ r Sl X }
\toprule
Iterations & Samples & Comments \\
\midrule
0 & \includegraphics[width=.6\textwidth, height=20mm, valign=M]{example-image} & Text is always being here\\
32 & \includegraphics[width=.6\textwidth, height=20mm, valign=M]{example-image} & Text \\
64 & \includegraphics[width=.6\textwidth, height=20mm, valign=M]{example-image} & Text \\
128 & \includegraphics[width=.6\textwidth, height=20mm, valign=M]{example-image} & Text \\
192 & \includegraphics[width=.6\textwidth, height=20mm, valign=M]{example-image} & Text \\
\vdots & \multicolumn{1}{c}{\vdots} & \multicolumn{1}{c}{\vdots} \\
3200 & \includegraphics[width=.6\textwidth, height=20mm, valign=M]{example-image} & Text \\
\bottomrule
\end{tabularx}
\label{tab4}
\end{table*}
\end{document}