Latex如何控制表格的宽度和高度 您所在的位置:网站首页 ppt表格固定了高度和宽度 Latex如何控制表格的宽度和高度

Latex如何控制表格的宽度和高度

2024-07-03 04:35| 来源: 网络整理| 查看: 265

原始的表格这样 \begin{table}[htbp] \centering \caption{Effect of Uncertainty Estimation.} \label{uncertain} \begin{tabular}{lccccccc} \toprule \multirow{2}{*}{~} &\multicolumn{3}{c}{Acc(\%)} &~ &\multicolumn{3}{c}{F1-score(\%)}\\ \cline{2-4} \cline{6-8} & CASME II & SAMM & SMIC-HS &~ & CASME II & SAMM & SMIC-HS \\ \midrule Deterministic &1 &1 &1 &~ &1 &1 &1\\ Uncertainty-Aware &\textbf{1} &\textbf{1} &\textbf{1} &~ &\textbf{1} &\textbf{7} &\textbf{78.64}\\ \bottomrule \end{tabular} \end{table}

可以手动输入设置自定义的表格宽度和高度: \resizebox{10mm}{12mm} 其中第一个括号表示的表格的宽度(或者也可以直接写为\textwidth,表示与文字宽度一致),第二个括号表示表格的高度。 整理后为:

\begin{table}[htbp] \centering \caption{Effect of Uncertainty Estimation.} \label{uncertain} \resizebox{10mm}{12mm}{ \begin{tabular}{lccccccc} \toprule \multirow{2}{*}{~} &\multicolumn{3}{c}{Acc(\%)} &~ &\multicolumn{3}{c}{F1-score(\%)}\\ \cline{2-4} \cline{6-8} & CASME II & SAMM & SMIC-HS &~ & CASME II & SAMM & SMIC-HS \\ \midrule Deterministic &1 &1 &1 &~ &1 &1 &1\\ Uncertainty-Aware &\textbf{1} &\textbf{1} &\textbf{1} &~ &\textbf{1} &\textbf{7} &\textbf{78.64}\\ \bottomrule \end{tabular}} \end{table}


【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有