[Tex/LaTex] LaTeX Error: File subfigure.sty not found

errorssubfloats

I'm getting this error when compiling:

! LaTeX Error: File `subfigure.sty' not found.

Here is part of the relevant code:

\documentclass[11pt]{article}

\usepackage{graphicx}
\usepackage{subfigure}

\setlength{\parindent}{1.4em}

\begin{document}    

\begin{figure}
    \subfigure[Scatter Plot]{
        \includegraphics[height=5cm]{graphs/scatter.pdf}
        \label{sub1}
    }
\end{figure}

\end{document}

Does the error message mean I don't have the subfigure package? Isn't that standard?

I've installed texlive and have run mktexlsr as suggested here but I'm still getting the error. How can I fix this?

Best Answer

In case you installed TeX Live from the packages of a Linux distro: Most distros split less-used LaTeX-packages into separate (Linux-distro)-packages. From the link in your question I assume that you are running Arch Linux. In this case you need to install the texlive-latexextra package which contains subfigure.sty. If you are using a different distro, the necessary package might be named differently (e.g. texlive-latex-extra in Debian/Ubuntu).

Also, as Peter notes, the subfigure package is depreciated.