我有以下最小示例:
\documentclass[12pt, oneside]{article}
\usepackage{booktabs}
\usepackage[a4paper,margin=1in]{geometry}
\begin{document}
\begin{table}[h!]
\caption{Final candidate genes}\label{tab:final}
\centering
\begin{tabular}{ll}
\toprule
& Gene\\
\midrule
Amplifications & ERLIN2 \\
& ERBB2 \\
& GAB1 \\
& PIK3CA\\
& PTK2 \\
\addlinespace
Deletions & SFMBT1 \\
& LATS1 \\
& MGAM \\
& PRSS2 \\
& DEFB130 \\
& ANXA8 \\
& PPYR1 \\
& FGFR2 \\
& CENTD2 \\
& PDE2A \\
& P2RY5 \\
& DNAH9 \\
& MAP2K4 \\
& ZNF18 \\
& FAM101B \\
& VPS53 \\
\bottomrule
\end{tabular}
\end{table}
\end{document}
当我运行它时,我希望“表 1”以粗体显示。有没有一个简单的包可以实现这一点?谢谢!:)
答案1
只需使用标题:
\usepackage{caption}
\captionsetup{labelfont={bf}}
我稍微简化了你的例子:
代码:
\documentclass{article}
\usepackage{booktabs,caption}
\captionsetup{labelfont=bf}
\begin{document}
\begin{table}
\caption{Final candidate genes}\label{tab:final}
\centering
\begin{tabular}{ll}
\toprule
Antelopes & Bazookas\\
\bottomrule
\end{tabular}
\end{table}
\end{document}