将所有图形放在一页上

将所有图形放在一页上

我想在一页上显示 6 张图片,但只有 4 张图片出现在一页上,另外 2 张图片出现在第二页上。有什么办法可以解决这个问题吗?非常感谢

\documentclass[12pt]{article}

\begin{figure}[h]
 \centering
 \begin{subfigure}[h]{0.49\textwidth}
   \caption*{Figure B3}
  \includegraphics[width=1\textwidth]{IPL Nationality Breakdown (Full Data Set).png} 
 \end{subfigure}%
 \hfill
 \begin{subfigure}[h]{0.49\textwidth}
   \caption*{Figure B4}
  \includegraphics[width=1\textwidth]{IPL Nationality Breakdown (SOLD).png}
 \end{subfigure}
 \end{figure}
 \vspace{0.05cm}
 \begin{figure}[h]
 \centering
 \begin{subfigure}[h]{0.49\textwidth}
   \caption*{Figure B5}
  \includegraphics[width=1\textwidth]{graph1.png} 
 \end{subfigure}%
  \hfill
 \begin{subfigure}[h]{0.49\textwidth}
   \caption*{Figure B6}
  \includegraphics[width=1\textwidth]{graph2.png}
 \end{subfigure}
 \end{figure}
  \begin{figure}[h]
 \centering
 \begin{subfigure}{0.49\textwidth}
   \caption*{Figure B7}
  \includegraphics[width=1\textwidth]{Relationship ipl exp auction price.png} 
 \end{subfigure}%
 \hfill
 \begin{subfigure}[h]{0.49\textwidth}
 \caption*{Figure B8}
  \includegraphics[width=1\textwidth]{IPL Bowling economy auction price.png}
 \end{subfigure}
 \end{figure}

\end{document}

我得到的输出

答案1

看看以下 MWE 是否能满足您的要求:

\documentclass{article}
\usepackage[demo]{graphicx}  % in real document remove `demo` option
\usepackage{caption,subcaption}
 \captionsetup[subfigure]{skip=0.5ex}

\begin{document}
\begin{figure}[ht]
 \centering
 \setkeys{Gin}{width=1\textwidth}
 \begin{subfigure}[t]{0.49\textwidth}
   \caption*{Figure B3}
  \includegraphics{IPL Nationality Breakdown (Full Data Set).png}
 \end{subfigure}%
 \hfill
 \begin{subfigure}[t]{0.49\textwidth}
   \caption*{Figure B4}
  \includegraphics{IPL Nationality Breakdown (SOLD).png}
 \end{subfigure}

\bigskip
 \begin{subfigure}[t]{0.49\textwidth}
   \caption*{Figure B5}
  \includegraphics{graph1.png}
 \end{subfigure}%
  \hfill
 \begin{subfigure}[t]{0.49\textwidth}
   \caption*{Figure B6}
  \includegraphics{graph2.png}
 \end{subfigure}

\bigskip
  \begin{subfigure}[t]{0.49\textwidth}
   \caption*{Figure B7}
  \includegraphics{Relationship ipl exp auction price.png}
 \end{subfigure}%
 \hfill
 \begin{subfigure}[t]{0.49\textwidth}
 \caption*{Figure B8}
  \includegraphics{IPL Bowling economy auction price.png}
 \end{subfigure}
    \end{figure}
 \end{document}

笔记:所有subfigure都在一个figure

在此处输入图片描述

相关内容