[Tex/LaTex] How to rotate a group of figures (subfigure)

rotatingsubfloats

3 figures side by side…

I want to put them horizontally, so that you need to rotate the book by 90° to read the figures and captions.

Now, I want to rotate this:

   \begin{figure}[]
\subfigure{
        \includegraphics[width=0.28\textwidth]{figures/a.png}
    }
    \label{sub:graph}
\subfigure{
        \includegraphics[width=0.28\textwidth]{figures/b.png}
    }
    \label{sub:mobile}
\subfigure{
        \includegraphics[width=0.28\textwidth]{figures/c.png}
    }
    \label{sub:dsk}

\caption{Main cap. \ref{sub:graph} sub cap1 \ref{sub:mobile} sub cap2 and \ref{sub:desktop} sub cap3.}
\label{fig:myFig}
   \end{figure}

Best Answer

Another way is to use the sidewaysfigure environment from the rotating package.

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{rotating}
\begin{document}
\begin{sidewaysfigure}
  \centering
  \includegraphics[width=0.28\textheight]{figures/a.png}\quad
  \includegraphics[width=0.28\textheight]{figures/b.png}\quad
  \includegraphics[width=0.28\textheight]{figures/c.png}
  \caption{Caption for the three rotated figures\label{fig:test}}
\end{sidewaysfigure}
\end{document}

This could be combined with subfig to have captions for each figure:

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{rotating}
\usepackage{subfig}
\begin{document}
\begin{sidewaysfigure}
  \centering
  \subfloat[First figure]{\includegraphics[width=0.28\textheight]{figures/a.png}\label{fig:a}} \quad
  \subfloat[Second figure]{\includegraphics[width=0.28\textheight]{figures/b.png}\label{fig:b}}\quad
  \subfloat[Third figure]{\includegraphics[width=0.28\textheight]{figures/c.png}\label{fig:c}}
  \caption{Caption for the three rotated figures\label{fig:test}}
\end{sidewaysfigure}
\end{document}

enter image description here