# Side caption in place of one subfigure

I currently have the following code displaying 5 subfigures:

\documentclass{article}
\usepackage{subcaption}
\usepackage{caption}
\usepackage{graphicx}

\begin{document}

\begin{figure*}[t]
\centering

\begin{subfigure}[b]{0.32\textwidth}
\centering
\includegraphics[width=\textwidth]{placeholder.png}
\caption{a}
\end{subfigure}
\begin{subfigure}[b]{0.32\textwidth}
\centering
\includegraphics[width=\textwidth]{placeholder.png}
\caption{b}
\end{subfigure}
\begin{subfigure}[b]{0.32\textwidth}
\centering
\includegraphics[width=\textwidth]{placeholder.png}
\caption{c}
\end{subfigure}

\begin{subfigure}[b]{0.32\textwidth}
\centering
\includegraphics[width=\textwidth]{placeholder.png}
\caption{d}
\end{subfigure}
\begin{subfigure}[b]{0.32\textwidth}
\centering
\includegraphics[width=\textwidth]{placeholder.png}
\caption{e}
\end{subfigure}

\caption{This is the caption...}
\label{fig:something}
\end{figure*}

\end{document}


I would like to save space (and make it look prettier) by having the caption replace a hypothetical 6th subfigure on the second row, instead of being under the whole figure. How can I do that?

You could achieve this by using minipages within the figure.
Therefore you put the subfigures you want to have below eachother in one minipage. Also set the width you want to have at the begining of the minipage and not in the subfigure.
As you may notice this leads to a different ordering in the pictures since picture (a) is now above and not to the left of picture (b).
Here is what I came up with:

\documentclass{article}
\usepackage{subcaption}
\usepackage{caption}
\usepackage{graphicx}

\begin{document}

\begin{figure*}[t]

\begin{minipage}[t]{0.32\textwidth}
\begin{subfigure}[b]{\textwidth}
\includegraphics[width=\textwidth]{edward.jpg}
\caption{a}
\end{subfigure}
\begin{subfigure}[b]{\textwidth}
\includegraphics[width=\textwidth]{edward.jpg}
\caption{b}
\end{subfigure}
\end{minipage}
\hfill
\begin{minipage}[t]{0.32\textwidth}
\begin{subfigure}[b]{\textwidth}
\includegraphics[width=\textwidth]{edward.jpg}
\caption{c}
\end{subfigure}
\begin{subfigure}[b]{\textwidth}
\includegraphics[width=\textwidth]{edward.jpg}
\caption{d}
\end{subfigure}
\end{minipage}
\hfill
\begin{minipage}[t]{0.32\textwidth}
\begin{subfigure}[b]{\textwidth}
\includegraphics[width=\textwidth]{edward.jpg}
\caption{e}
\end{subfigure}
\caption{This is the caption...}
\label{fig:something}
\end{minipage}

\end{figure*}

\end{document}


Note: I changed the name of the included graphic.

The resulting output: