繪製 IEEE 存取格式的 5 個子表

繪製 IEEE 存取格式的 5 個子表

我正在嘗試為我的 IEEE 格式論文(雙欄)繪製 5 個子表(每個文字寬度 3 個)。然而,我用谷歌搜尋瞭如何繪製它,在過去的一小時內嘗試了一些程式碼,但無法成功繪製它。

我的子表代碼:

\documentclass{ieeeaccess}
\usepackage{supertabular}
\usepackage{caption, subcaption}

\begin{table*}[h]
    \begin{subtable}[h]{0.33\textwidth}
        \centering
        \begin{tabular}{l | l | l}
        Day & Max Temp & Min Temp \\
        \hline \hline
        Mon & 20 & 13\\
        Tue & 22 & 14\\
        Wed & 23 & 12\\
        Thurs & 25 & 13\\
        Fri & 18 & 7\\
        Sat & 15 & 13\\
        Sun & 20 & 13
       \end{tabular}
       \caption{First Week}
       \label{tab:week1}
    \end{subtable}
    \hfill
    \begin{subtable}[h]{0.33\textwidth}
        \centering
        \begin{tabular}{l | l | l}
        Day & Max Temp & Min Temp \\
        \hline \hline
        Mon & 17 & 11\\
        Tue & 16 & 10\\
        Wed & 14 & 8\\
        Thurs & 12 & 5\\
        Fri & 15 & 7\\
        Sat & 16 & 12\\
        Sun & 15 & 9
        \end{tabular}
        \caption{Second Week}
        \label{tab:week2}
    \end{subtable}
    \begin{subtable}[h]{0.33\textwidth}
        \centering
        \begin{tabular}{l | l | l}
        Day & Max Temp & Min Temp \\
        \hline \hline
        Mon & 20 & 13\\
        Tue & 22 & 14\\
        Wed & 23 & 12\\
        Thurs & 25 & 13\\
        Fri & 18 & 7\\
        Sat & 15 & 13\\
        Sun & 20 & 13
       \end{tabular}
       \caption{First Week}
       \label{tab:week1}
    \end{subtable}
     \caption{Max and min temps recorded in the first two weeks of July}
     \label{tab:temps}
\end{table*}
EOD

\end{document}

但是,我對這三個表的輸出如下圖所示。 輸出影像

答案1

你的作業系統選項定位一團糟subtable。請嘗試以下操作:

\documentclass{ieeeaccess}
\usepackage{graphicx} % <--- had to be in preamble
\usepackage{subcaption}
\usepackage{makecell}

\begin{table*}
\centering
    \begin{subtable}[t]{0.3\textwidth}
        \centering
        \begin{tabular}{l | l | l}
        Day & \makecell{Max\\ Temp} & \makecell{Min\\ Temp} \\
        \hline \hline
        Mon & 20 & 13\\
        Tue & 22 & 14\\
        Wed & 23 & 12\\
        Thurs & 25 & 13\\
        Fri & 18 & 7\\
        Sat & 15 & 13\\
        Sun & 20 & 13
       \end{tabular}
       \caption{First Week}
       \label{tab:week1}
    \end{subtable}
    \hfil
    \begin{subtable}[t]{0.3\textwidth}
        \centering
        \begin{tabular}{l | l | l}
        Day & \makecell{Max\\ Temp} & \makecell{Min\\ Temp} \\
        \hline \hline
        Mon & 17 & 11\\
        Tue & 16 & 10\\
        Wed & 14 & 8\\
        Thurs & 12 & 5\\
        Fri & 15 & 7\\
        Sat & 16 & 12\\
        Sun & 15 & 9
        \end{tabular}
        \caption{Second Week}
        \label{tab:week2}
    \end{subtable}
    \hfil
    \begin{subtable}[t]{0.3\textwidth}
        \centering
        \begin{tabular}{l | l | l}
        Day & \makecell{Max\\ Temp} & \makecell{Min\\ Temp} \\
        \hline \hline
        Mon & 20 & 13\\
        Tue & 22 & 14\\
        Wed & 23 & 12\\
        Thurs & 25 & 13\\
        Fri & 18 & 7\\
        Sat & 15 & 13\\
        Sun & 20 & 13
       \end{tabular}
       \caption{First Week}
       \label{tab:week1}
    \end{subtable}
    \caption{Max and min temps recorded in the first two weeks of July}
     \label{tab:temps}
\end{table*}
\lipsum\lipsum
\EOD   % <---
\end{document} 

在此輸入影像描述

相關內容