2

For an appendix I am trying to create rotated tables and I am using the landscape mode for this. Only one problem is holding me back; As soon as I am trying to add the title of the appendix to the tables I created, either the title is rotated ( see the following code):

\begin{landscape}
\section{blabla}
    \begin{table}
     blablabla
    \end{table}
\end{landscape}

Or when I write the section name outside the landscape mode, The title starts on an empty page and the tables start on the next page (which is ugly).(see following code):

\section{blabla}
\begin{landscape}
     \begin{table}
     blablabla
     \end{table}
\end{landscape}

Does anyone know how to solve this?

  • 2
    landscape always starts a new page. If it is only the table you want to rotate, try sidewaystable (I think it is in the rotating package). Besides your title in the subject is a bit confusing, people might thing a table caption is title instead – daleif Jun 7 '13 at 12:14
2

The hvfloat package is highly flexible and offers you the possibility to have several rotated tables in one page; in the following example I deactivated flotation for all tables, using the nonFloat=true option; notice also the capWidth=w option so the caption width will be the same as the table width:

\documentclass{article}
\usepackage[a6paper]{geometry}% just for the example
\usepackage{booktabs}
\usepackage{hvfloat}

\begin{document}

\section{Test Section with Several Rotated Objects}

\hvFloat[%
nonFloat=true,%
capWidth=w,%
capPos=t,%
rotAngle=90,%
objectPos=c%
]{table}{%
    \begin{tabular}{ll}
    \toprule
    column1a & column2a \\
    column2b & column2b \\
    column1c & column2c \\
    column1d & column2d \\
    \bottomrule
    \end{tabular}%
}{%
A test rotated table}{tab:test1}

\vfill

\hvFloat[%
nonFloat=true,%
capWidth=w,%
capPos=t,%
rotAngle=90,%
objectPos=c%
]{table}{%
    \begin{tabular}{ll}
    \toprule
    column1a & column2a \\
    column2b & column2b \\
    column1c & column2c \\
    column1d & column2d \\
    \bottomrule
    \end{tabular}%
}{Another test rotated table}{tab:test2}

\end{document}

enter image description here

2

How about this...

enter image description here

\documentclass{article}
\usepackage{rotating}
\begin{document}

\section{Hello}

My table is in Table~\ref{tab:hello}.
\begin{table}
  \begin{sideways}
    \begin{tabular}{lllllllll}
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello \\
    hello & hello & hello & hello & hello & hello & hello & hello & hello
    \end{tabular}
  \end{sideways}
  \centering
  \caption[Caption]{Caption.}
  \label{tab:hello}
\end{table}
\end{document}
  • This would work indeed, except that I can only get one table on each page ... – user31880 Jun 7 '13 at 12:46
  • Aha, a new problem. This might be best tackled by you opening a new question. Give a minimal working example to show the layout problem you're having, and we'll find a solution for you :-). – John Wickerson Jun 7 '13 at 12:55

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.