横向表格未位于中心

横向表格未位于中心

我正在使用 overleaf 准备我的文档。我试图在横向环境中绘制表格。下面是我为该表格使用的脚本。

\usepackage{array}
\usepackage{adjustbox}

\begin{document}
\begin{sidewaystable}
  \caption{Comparison of Related Work regarding Entity Resolution.}
  \begin{adjustbox}{width=\columnwidth,center}
  \begin{tabular}{|>{\bfseries}c|*{6}{c|}}\hline
    \multirow{2}{*}{\bfseries Paper} & \multicolumn{2}{c|}{\bfseries Schema Awareness} & \multicolumn{2}{c|}{\bfseries Algorithmic Foundation} & \multirow{2}{*}{\bfseries Incremental} & \multirow{2}{*}{\bfseries Crows-Sourcing} \\
    \cline{2-5}
                       & \textbf{Schema Aware} & \textbf{Schema Agnostic} & \textbf{Non-Learning}       & \textbf{Learning-based} & &\\ 
                       \hline
    Swoosh \cite{r45}                           & \checkmark   &   & \checkmark   &   &   & \\ 
    \hline
    D-Swoosh \cite{r46}                         & \checkmark   &   & \checkmark   &   &   & \\ 
    \hline
    LINDA \cite{r34}                            &   & \checkmark   & \checkmark   &   &   & \\ 
    \hline
    MinoanER \cite{r47}                         &   & \checkmark   & \checkmark   &   &   & \\ 
    \hline
    Gradient-based Matching \cite{r26}          & \checkmark   &   &   & \checkmark   &   & \\ 
    \hline 
    BN-based ER \cite{r49}                      &   & \checkmark   &   & \checkmark   & \checkmark   & \\ 
    \hline
    Deep Seq-2-Seq ER \cite{r51}                & \checkmark   & \checkmark   &   & (\checkmark)   &   & \\ 
    \hline
    Deep Matcher \cite{r9}                      & \checkmark   &   &   & (\checkmark)   &   & \\ 
    \hline
    DeepER \cite{r19}                           & \checkmark   &   &   & (\checkmark)   &   & \\ 
    \hline
    Schema-Agnostic ER \cite{r64}               & \checkmark   & \checkmark   &   & (\checkmark*)   &   & \\ 
    \hline
    DITTO \cite{r8}                             & \checkmark   & \checkmark   &   & (\checkmark*)   &   & \\ 
    \hline
    Task-based parallelization ER \cite{r69}    & \checkmark   & \checkmark   & \checkmark   &  & \checkmark   & \\ 
    \hline
    Crowd-ER \cite{70}                          & \checkmark   &   & \checkmark   &   &   & \checkmark \\ 
    \hline
    \bfseries Our System                        & \checkmark   & \checkmark   &   & (\checkmark*)   & \checkmark   & \checkmark \\ 
    \hline
  \end{tabular}
  \end{adjustbox}
\end{sidewaystable}
\end{document}
}

我尝试了\centering\begin{center}输出仍然如图所示。

有人能帮我解决这个问题吗?

先感谢您。

请参阅图像以了解输出。在此处输入图片描述

答案1

  • 您的文档示例并不完整,它只是缺少的片段,然后是定义和的documentclass包。sidewaystable\checkmark
  • 添加错过的包裹表格在页面中央
  • 对于表格,我将使用 ˙tabularray` 包(由于表格简单,可以在 Overlef 服务上进行编译)
documentclass{article}
\usepackage{dingbat}
\newcommand\cm{\checkmark}  % abrevation for \checkmark

\usepackage{tabularray}
\usepackage{rotating}

\begin{document}
\begin{sidewaystable}
\caption{Comparison of Related Work regarding Entity Resolution.}
    \begin{tblr}{hlines, vlines,
               colspec = {l *{6}{X[c]} },
               colsep  = {4pt},
              row{1,2} = {font=\bfseries}
               } 
%  
\SetCell[r=2]{l}    Paper
    &   \SetCell[c=2]{c} Schema Awareness
            &       &   \SetCell[c=2]{c} Algorithmic Foundation
                            &       &   \SetCell[r=2]{c}    Incremental
                                            &   \SetCell[r=2]{c}    Crows-Sourcing  \\
Schema Aware
    & Schema Agnostic
            & Non- Learning
                    & Learning- based
                            &       &       &       \\
Swoosh \cite{r45}
    & \cm   &       & \cm   &       &       &       \\
D-Swoosh \cite{r46}
    & \cm   &       & \cm   &       &       &       \\
LINDA \cite{r34}                            
    &       & \cm   & \cm   &       &       &       \\
MinoanER \cite{r47}                         
    &       & \cm   & \cm   &       &       &       \\
Gradient-based Matching \cite{r26}          
    & \cm   &       &       & \cm   &       &       \\
BN-based ER \cite{r49}                      
    &       & \cm   &       & \cm   & \cm   &       \\
Deep Seq-2-Seq ER \cite{r51}                
    & \cm   & \cm   &       & (\cm) &       &       \\
Deep Matcher \cite{r9}                      
    & \cm   &       &       & (\cm) &       &       \\
DeepER \cite{r19}                           
    & \cm   &       &       & (\cm) &       &       \\
Schema-Agnostic ER \cite{r64}              
    & \cm   & \cm   &       & (\cm*)&       &       \\
DITTO \cite{r8}                             
    & \cm   & \cm   &       & (\cm*)&       &       \\
Task-based parallelization ER \cite{r69}    
    & \cm   & \cm   & \cm   &       & \cm   &       \\
Crowd-ER \cite{70}                          
    & \cm   &       & \cm   &       &       & \cm   \\
\textbf{Our System}                       
    & \cm   & \cm   &       & (\cm*)& \cm   & \cm   \\
    \end{tblr}
\end{sidewaystable}
\end{document}

在此处输入图片描述

相关内容