4

I have downloaded the package float in order to help in placing figures where I would like them. At the moment, 'All' figures are placed at the 'end' of document.

I have run the script 'float.dtx.

Subsequently, the [H] option has been inserted as seen below example; however, nothing has changed and the figures still appear at the end of document.

Does any one have an idea as to what is needed to activate the float programs appropriately or as to how to implement them?

Thank you.

%%%%% Inserting figure %%%%%%%%%%%%%%

\begin{figure}[H] 
\begin{center}
 \maketitle {\bf Title}
  \includegraphics[scale=0.9]{Figure}
 \caption{Explanatory statement}
\label{}
 \end{center} 
\end{figure}
Guido
  • 30,740
Anna
  • 41

2 Answers2

4

Your demand is against to basic rule of TeX/LaTeX: figures and tables (and similar object) should be in float environments that can be moved to place, where the best fit into the text ...

To achieve, what you like, is the simplest way not to use floats. Just put figure directly in text and for caption use \captionof from package caption or small package captionof when you like to use caption formatting facility of used document class:

\documentclass{article}
    \usepackage{graphicx}
    \usepackage{capt-of}

    \usepackage{lipsum}

\begin{document}
    \lipsum[1]
\begin{center}
    \includegraphics[width=0.5\textwidth]{example-image}
\captionof{figure}{My caption}
    \label{fig:mc-1}
\end{center}
See Fig.~\ref{fig:mc-1} ...
    \lipsum[2]
\end{document}

enter image description here

Zarko
  • 296,517
1

Why do you need the float package ?

First read about figure placement and try with the following:

\documentclass{article}
\usepackage{graphicx}

\begin{document}

\begin{figure}[!htbp] 
  \centering
  \textbf{Your title}\\
  \includegraphics[width=.5\textwidth]{fig}
  \caption{Explanatory statement \label{fig:fig1}}
\end{figure}

\end{document}
t-bltg
  • 237
  • 5
    that does not ensure that the figure is placed exactly here. – Johannes_B Nov 22 '15 at 08:44
  • Yes, but the main problem here was I quote: "All' figures are placed at the 'end' of document", therefore it preferably not advised to use H ...

    if 'exactly here' is needed then why use a floating env ? see here: http://tex.stackexchange.com/a/8631/75098

    – t-bltg Nov 22 '15 at 09:19
  • @neok H floats wil never go to the end of the document if H is defined. So the OP had not loaded the float package. – David Carlisle Nov 22 '15 at 10:52