내 테이블이 threeparttable을 중심으로 배치되지 않는 이유는 무엇입니까?

내 테이블이 threeparttable을 중심으로 배치되지 않는 이유는 무엇입니까?

누구든지 threeparttable, TPTMinimum 재정의 및 센터링 환경으로 내 문제를 해결하도록 도와줄 수 있습니까? 나는 다른 어떤 주제에서도 내가 하려고 했던 것을 본 적이 없습니다.

나는 다음과 같은 것을 가지고 있습니다 :

\begin{table}
\centering
\begin{threeparttable}
\renewcommand\TPTminimum{\linewidth}
\captionsetup{font=small}

\begin{tabular}{|c|c|c|c|}
\hline\hline
{\scriptsize \textbf{Parameter}} & {\scriptsize \textbf{Value}}    & {\scriptsize \textbf{Unity}}   & {\scriptsize \textbf{Reference/Comment}}\\\hline
$\scriptstyle \tau_1$            & $\scriptstyle 10^{-2}$          & $\scriptstyle\text{dia}^{-1}$  & {\scriptsize \citet{Spratt}}\\\hline
$\scriptstyle \tau_2$            & $\scriptstyle 10^{-3}$          & $\scriptstyle\text{dia}^{-1}$  & $\scriptstyle \tau_2 \; < \; \tau_1$\\\hline
%some more lines...
$\scriptstyle \lambda$           & $\scriptstyle 4.16$             & $\scriptstyle\text{dia}^{-1}$  & {\scriptsize \citet{REF2}\tnote{2}}\\\hline
$\scriptstyle a$                 & $\scriptstyle 2 \times 10^{3}$  & {\scriptsize mg}               & {\scriptsize \citet{REF1}\tnote{1}}\\\hline
$\scriptstyle b$                 & $\scriptstyle 5 \times 10^{6}$  & {\scriptsize mg}               & {\scriptsize \citet{REF1}\tnote{1}}\\
\hline\hline
\end{tabular}
%NOTES:
\begin{tablenotes}[flushleft]\footnotesize
\item[1] I want it that way because my table isn't so big and the footnotes are getting weird the original way...
\item[2] \,Second Note!
\end{tablenotes}
\end{threeparttable}
\caption{Parameters...}
\end{table}

그것은 어떻게 생겼어: IMG

이 테이블을 어떻게 중앙 집중화할 수 있나요? 감사해요!

답변1

제안 사항과 유사하게 상자 tabular내부 를 설정하십시오 .\makebox[\linewidth]여백을 무시하고 이미지를 중앙에 배치:

\documentclass{article}
\usepackage{amsmath,caption,threeparttable,booktabs}
\newcommand{\citet}[1]{#1}% Just for this example
\begin{document}
\begin{table}
  \begin{threeparttable}
    \renewcommand\TPTminimum{\linewidth}
    \captionsetup{font=small}
    \makebox[\linewidth]{\scriptsize%
    \begin{tabular}{cccc}
      \toprule
      \textbf{Parameter} & \textbf{Value}    & \textbf{Unity} & \textbf{Reference/Comment} \\
      \midrule
      $\tau_1$            & $10^{-2}$          & $\text{dia}^{-1}$  & \citet{Spratt} \\
      $\tau_2$            & $10^{-3}$          & $\text{dia}^{-1}$  & $\tau_2 \; < \; \tau_1$ \\
      %some more lines...
      $\lambda$           & $4.16$             & $\text{dia}^{-1}$  & \citet{REF2}\tnote{2} \\
      $a$                 & $2 \times 10^{3}$  & mg               & \citet{REF1}\tnote{1} \\
      $b$                 & $5 \times 10^{6}$  & mg               & \citet{REF1}\tnote{1} \\
      \bottomrule
    \end{tabular}}
    %NOTES:
    \begin{tablenotes}[flushleft]\footnotesize
      \item[1] I want it that way because my table isn't so big and the footnotes are getting weird the original way...
      \item[2] \,Second Note!
    \end{tablenotes}
  \end{threeparttable}
  \caption{Parameters...}
\end{table}
\end{document}

여기에 이미지 설명을 입력하세요

답변2

내 생각입니다. 또한 threeparttablex다른 기능 중에서 메모의 글꼴 크기를 전체적으로 설정할 수 있다는 점을 고려하십시오.

상단에 캡션을 배치해두었습니다.그리고하단의 캡션은 독자를 혼란스럽게 할 뿐입니다. \text수학에서 텍스트가 아닌 설정을 똑바로 사용하지 마십시오 . 이것은 하나의 단위이므로 실제로는 ( )처럼 처리되어야 합니다 siunitx.

\documentclass{article}
\usepackage{amsmath,threeparttable}
\usepackage[tableposition=top]{caption}
\usepackage{booktabs}
\captionsetup{font=small}
\newcommand{\citet}[1]{#1}% Just for this example
\begin{document}
\begin{table}
  \centering
  \caption{Parameters...}
  \begin{threeparttable}
    \scriptsize
    \begin{tabular}{
        c l c l c l c
      }
      \toprule
      {\textbf{Parameter}} && {\textbf{Value}}
      && {\textbf{Unity}} && {\textbf{Reference/Comment}}
      \\
      \midrule
      $ \tau_1$            && $ 10^{-2}$
      && $\mathrm{dia}^{-1}$  && {\citet{Spratt}}
      \\
      $ \tau_2$            && $ 10^{-3}$
      && $\mathrm{dia}^{-1}$  && $ \tau_2 < \tau_1$
      \\
      % some more lines...
      $ \lambda$           && $ 4.16$
      && $\mathrm{dia}^{-1}$  && {\citet{REF2}\tnote{2}}
      \\
      $ a$                 && $ 2 \times
      10^{3}$  && {mg}               && {\citet{REF1}\tnote{1}}
      \\
      $ b$                 && $ 5 \times
      10^{6}$  && {mg}               && {\citet{REF1}\tnote{1}}
      \\
      \bottomrule
    \end{tabular}
    %NOTES:
    \begin{tablenotes}%[flushleft]
      \footnotesize
      \item[1] I want it that way because my table isn't so big and the footnotes are getting weird the original way...
      \item[2] Second Note!
    \end{tablenotes}
  \end{threeparttable}
\end{table}
\end{document}

(이미지와 코드가 100% 일치하지 않습니다)

여기에 이미지 설명을 입력하세요

관련 정보