2

I have a two-column article document in which I want to place a figure spanning both columns above two (independent) tables (using tabularx), one in each column. I've followed the answer here, but it gives me tables and figures on separate pages. What am I doing wrong?

MWE:

\documentclass[twocolumn]{article}
\usepackage{mwe}
\usepackage{tabularx}
\usepackage{graphicx}
\begin{document}

\begin{figure*}
\centering
\includegraphics[width=0.5\textwidth]{example-image-a}
\end{figure*}

\begin{tabularx}{\columnwidth}{l|X}
1 & Some text\\
2 & Some more text 
\end{tabularx} 

\newpage

\begin{tabularx}{\columnwidth}{l|X}
3 & Some text\\
4 & Some more text 
\end{tabularx} 

\end{document}
3

Almost right:-) But figure* always comes the page after it appears in the source so you can't do this on the first page (if you need that you need to do something a bit trickier) and you need \noindent to avoid a paragraph indentation making your full width tables not fit on a line.

enter image description here

\documentclass[twocolumn]{article}
\usepackage{tabularx}
\usepackage{graphicx}
\begin{document}



\begin{figure*}
\centering
\includegraphics[width=0.5\textwidth]{example-image-a}
\end{figure*}

aaa

\pagebreak

aaa

\pagebreak

\noindent\begin{tabularx}{\columnwidth}{l|X}
1 & Some text\\
2 & Some more text 
\end{tabularx} 

\newpage

\noindent\begin{tabularx}{\columnwidth}{l|X}
3 & Some text\\
4 & Some more text 
\end{tabularx} 

\end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.