ラテックス図の番号は、部品 a、b、c として付けられています。

ラテックス図の番号は、部品 a、b、c として付けられています。

記事を書いているのですが、図を並べて表示する必要があります。次のリンクのコマンドを使用しました。3枚の画像を水平に並べるにはどうすればいいですか?それを行うには、図 1、図 2、図 3 のように、図に順番に番号が付けられています。これらすべてを同じ図 1 の一部にし、(a)、(b)、(c) などのサブセクションを持たせたいと思います。

答え1

subcaptionパッケージとその環境を使用することもできますsubfigure。次の例では、サブ図がテキストブロックの全幅を占めるように設定しています。また、各サブ図に関連付けられたグラフの幅がすべて同じであると想定しています。そうでない場合は、サブsubfigure図の幅を適切に調整するだけです。

ここに画像の説明を入力してください

\documentclass{article}
\usepackage{subcaption}
\usepackage[demo]{graphicx} % omit 'demo' for real document

\begin{document}

\begin{figure}
  \begin{subfigure}{0.31\textwidth}
    \includegraphics[width=\linewidth]{fig_a.pdf}
    \caption{First subfigure} \label{fig:1a}
  \end{subfigure}%
  \hspace*{\fill}   % maximize separation between the subfigures
  \begin{subfigure}{0.31\textwidth}
    \includegraphics[width=\linewidth]{fig_b.pdf}
    \caption{Second subfigure} \label{fig:1b}
  \end{subfigure}%
  \hspace*{\fill}   % maximizeseparation between the subfigures
  \begin{subfigure}{0.31\textwidth}
    \includegraphics[width=\linewidth]{fig_c.pdf}
    \caption{Third subfigure} \label{fig:1c}
  \end{subfigure}

\caption{A figure that contains three subfigures} \label{fig:1}
\end{figure}

\end{document}

答え2

次のパッケージを使用できますsubfig:

\usepackage{subfig}

\begin{figure}[htbp]
\subfloat[subfig-a's caption]{\includegraphics[height=1.8in]{...}}
\subfloat[subfig-b's caption]{\includegraphics[height=1.8in]{...}}
\subfloat[subfig-c's caption]{\includegraphics[height=1.8in]{...}}
\caption{...}
\end{figure}

関連情報