12

I have an image and a table that I want to display on a page. Each eats up little less than half of the space available so there's not much room for any other stuff on that page, but I know there is enough space for both. I tried to place them with [ht] and [hb], both [h] and both [ht] but still I can't get those two on the same page but instead at least few paragraphs between them. [ht]+\clearpage works fine but it produces lots of white spaces in the pages How do I force those two to stay on the same page without putting white spaces in the rest of the pages.

this is my code:

\begin{figure*}[ht]
{\includegraphics[width=\linewidth]{pic1}}\caption{example_fig} 
\label{fig1}
\end{figure*}

\begin{table*}[ht]
\begin{tabularx}{\linewidth}{@{}>{\hsize=0.8\hsize}X *2{>{\hsize=1.1\hsize}X}@{}}
a & b & c \\[0.7ex]
\end{tabularx}
\caption{example}
\label{tab:template}
\end{table*}
\clearpage
1

1 Answer 1

11

By using [ht] You have prevented the use of a float page which would mos t likely have solved your problem, just omit the optional argument. and if necessary put \clearpage after the pair of floats.

Not the answer you're looking for? Browse other questions tagged .