我正在尝试在 1 个标题下插入多个图形。我使用 subfloat,不知道如何将所有图形放入 1 页文档中。有人能帮我吗?提前谢谢!
\begin{figure}
\centering
\begin{tabular}{cccc}
\subfloat{\includegraphics[width=.8\linewidth]{fig1}} &
\subfloat{\includegraphics[width=.8\linewidth]{fig2}} & \\
\subfloat{\includegraphics[width=.8\linewidth]{fig3}} &
\subfloat{\includegraphics[width=.8\linewidth]{fig4}}\\
\subfloat{\includegraphics[width=.8\linewidth]{fig5}}\\
\end{tabular}
\caption{correlation}
\end{figure}
答案1
像这样?
\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{subfig}
\begin{document}
\begin{figure}
\centering
\subfloat{\includegraphics[width=.48\linewidth]{fig1}}
\hfill
\subfloat{\includegraphics[width=.48\linewidth]{fig2}}
\subfloat{\includegraphics[width=.48\linewidth]{fig3}}
\hfill
\subfloat{\includegraphics[width=.48\linewidth]{fig4}}\
\subfloat{\includegraphics[width=.48\linewidth]{fig5}}\\
\caption{correlation}
\label{fig:corr}
\end{figure}
\end{document}
编辑:
你也可以得到类似的结果,正如指出的那样埃格尔在下面的评论中,也没有使用\subfloat
环境:
\documentclass{article}
\usepackage[demo]{graphicx}
\begin{document}
\begin{figure}
\centering
\includegraphics[width=.48\linewidth]{fig1}
\hfill
\includegraphics[width=.48\linewidth]{fig2}
\medskip
\includegraphics[width=.48\linewidth]{fig3}
\hfill
\includegraphics[width=.48\linewidth]{fig4}
\medskip
\includegraphics[width=.48\linewidth]{fig5}
\caption{correlation}
\label{fig:corr}
\end{figure}
\end{document}