Page Layoutpage numbering on multiple documents

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
murph636
Posts: 22
Joined: Sun Mar 15, 2009 3:54 am

Re: page numbering on multiple documents

Post by murph636 »

Thanks, I will check again to see what I am missing. However, I do notice that your result on page 41 (not numbered) still has a blank page inserted in front of a sideways table. Any ideas on how to fix that?

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

page numbering on multiple documents

Post by localghost »

For some reason all of your pages are unnumbered (except chapter pages). The reason for the behaviour on page 41 is that the sidewaystable environment starts a new page and occupies it completely. Refer to the rotating manual to learn more about that and how to use the sideways environment on this page. Other useful hints are available with the epslatex document.
murph636
Posts: 22
Joined: Sun Mar 15, 2009 3:54 am

page numbering on multiple documents

Post by murph636 »

Thanks, I am still trying to figure out the rotating business. I can't seem to get anything to work. I have tried this:

Code: Select all

\begin{landscape}
\centering
\includegraphics[width=0.8\textwidth]{./historical3.png}
\label{Historical}
\end{landscape}
but that has the same result as sidewaysfigure...
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

page numbering on multiple documents

Post by localghost »

I don't think that I talked about the landscape environment in my last reply though mentioning the linked document.
murph636
Posts: 22
Joined: Sun Mar 15, 2009 3:54 am

page numbering on multiple documents

Post by murph636 »

I have managed to fix rotating my first figure so it includes the section header on the same page using this code:

Code: Select all

\newpage
\section{Figures}
\renewcommand{\topfraction}{0.85}
\renewcommand{\textfraction}{0.1}
\renewcommand{\floatpagefraction}{0.75}
\begin{figure}[ht]
\begin{center}
\begin{minipage}[c]{0.9\linewidth}
\includegraphics[angle=90,width=1\textwidth]{./historical3.png}
\end{minipage}\hfill
\begin{minipage}[c]{0.1\linewidth}
\rotcaption[The natural vegetation at the time of the public land surveys between 1847-1907 within 50 km of the TGO \citep{Marschner1930}.]{\label{Historical}}
\end{minipage}
\end{center}
\end{figure}

However, I cannot seem to get the same method to work for a table. Sidewaystable always forces the table onto the next page, I tried using \rotatebox, but that gave me several errors.

I would really appreciate any help in getting my first table of the section to be sideways and include the section header. Here's an example table:

Code: Select all


\newpage
\clearpage
\section{Tables}
\begin{sidewaystable}
\centering
\caption{Error matrix from 2001 NLCD classification of Level 1 classes.}
\begin{tabular}{m{1in}rrrrrrrr}
\toprule
           &    \multicolumn{ 6}{c}{2005 Aerial Photo Interpretation Reference Data} &            &            \\ [1ex]           
\cline{2-7} 
 &      &       &       &       &       &       &            &            \\ 
 NLCD 2001 & Agriculture &     Forest &  Grassland &      Urban &      Water &    Wetland &     Totals & User's  \\ 
 Classified Data &  &      &   &       &       &     &      & Accuracy (\%) \\ [1ex]
\hline
 &      &       &       &       &       &       &            &            \\ 
Agriculture &       161 &          7 &          6 &         13 &          0 &          0 &        187 &      86.1 \\[1ex]
    Forest &          7 &         25 &          6 &          8 &          2 &         10 &         58 &      43.1 \\[1ex]
 Grassland &         36 &         16 &         21 &         14 &          1 &          1 &         89 &      23.6 \\[1ex]
     Urban &         12 &          8 &          8 &         94 &          1 &          3 &        126 &      74.6 \\[1ex]
     Water &          1 &          3 &          2 &          1 &         17 &          2 &         26 &      65.4 \\[1ex]
   Wetland &          1 &          1 &          2 &          1 &          1 &          8 &         14 &      57.1 \\[1ex]
    Totals &        218 &         30 &         45 &        131 &         22 &         24 &        500 &            \\[1ex]
Producer's &      &       &       &       &       &       &            &            \\ 
Accuracy (\%) &      73.9 &      41.7 &      46.7 &      71.8 &      77.3 &      33.3 &            &            \\[1ex]
\hline 
 &      &       &       &       &       &       &            &            \\ 
\multicolumn{ 9}{l}{Overall accuracy = 65.2$\%$; Overall Kappa coefficient = 0.53; Overall Kappa Z Statistic = 19.5$^*$} \\
\bottomrule
\end{tabular}
\label{NLCDLevel1Table}
\end{sidewaystable}
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

page numbering on multiple documents

Post by localghost »

murph636 wrote:[...] However, I cannot seem to get the same method to work for a table. Sidewaystable always forces the table onto the next page, I tried using \rotatebox, but that gave me several errors.

I would really appreciate any help in getting my first table of the section to be sideways and include the section header. [...]
I already suggested the sideways environment from the rotating package. It turns only its contents and will keep your section heading in place. Just put your table in and see the result. That's all I can do for the moment.
murph636
Posts: 22
Joined: Sun Mar 15, 2009 3:54 am

Re: page numbering on multiple documents

Post by murph636 »

I am very sorry, I finally have the sideways environment working for the table and the section header stays on the page. However, it stretches the table horizontally and goes over the right page margin. Also, I keep getting an error about the caption being outside the float, how do I avoid that?
murph636
Posts: 22
Joined: Sun Mar 15, 2009 3:54 am

Re: page numbering on multiple documents

Post by murph636 »

I have been trying to figure out the caption issue and found \captionof as a solution. However, when trying to rotate the caption using \rotcaptionof, it rotates all the captions from that point forward and forces my first table to jump to the next page. If I can figure out how to stop the table from stretching, the rotated caption and the table will be on the same page as my section header, ideally. Then, I need to figure out how to rotate just the one caption, leaving the rest as-is.
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

page numbering on multiple documents

Post by localghost »

The whole matter is indeed very tricky. I finally have been able to prepare a workaround.

Code: Select all

%\listfiles
\documentclass[12pt,english]{report}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{babel}
\usepackage[top=1in,bottom=1.1in,left=1.5in,right=1in]{geometry}
\usepackage[font=small,labelfont=bf,tableposition=top]{caption}
\usepackage{array,booktabs}
\usepackage[doublespacing]{setspace}
\usepackage{rotating}

\begin{document}
  \section{Tables}

    \bigskip\bigskip
    \begin{sideways}
    \begin{minipage}{0.8\textheight}
       \centering
       \captionof{table}{Error matrix from 2001 NLCD classification of Level 1 classes.}\label{tab:NLCDLevel1Table}
      \begin{tabular}{m{1in}rrrrrrrr} \toprule
        & \multicolumn{ 6}{c}{2005 Aerial Photo Interpretation Reference Data} &  & \\ \cmidrule{2-7}
        NLCD 2001 & Agriculture & Forest & Grassland & Urban & Water & Wetland & Totals & User's  \\
        Classified Data & & & & & & & & Accuracy (\%) \\ \midrule
        Agriculture & 161 & 7 & 6 & 13 & 0 & 0 & 187 & 86.1 \\
        Forest & 7 & 25 & 6 & 8 & 2 & 10 & 58 & 43.1 \\
        Grassland & 36 & 16 & 21 & 14 & 1 & 1 & 89 & 23.6 \\
        Urban & 12 & 8 & 8 & 94 & 1 & 3 & 126 & 74.6 \\
        Water & 1 & 3 & 2 & 1 & 17 & 2 & 26 & 65.4 \\
        Wetland & 1 & 1 & 2 & 1 & 1 & 8 & 14 & 57.1 \\ \addlinespace
        Totals & 218 & 30 & 45 & 131 & 22 & 24 & 500 & \\ \addlinespace
        Producer's & & & & & & & & \\
        Accuracy (\%) & 73.9 & 41.7 & 46.7 & 71.8 & 77.3 & 33.3 & & \\ \midrule
        \multicolumn{9}{l}{Overall accuracy = 65.2$\%$; Overall Kappa coefficient = 0.53; Overall Kappa Z Statistic = 19.5$^*$} \\ \bottomrule
      \end{tabular}
    \end{minipage}
    \end{sideways}
\end{document}
All the efforts you mentioned didn't work for me as well. A proper alignment is very difficult and nearly impossible. This concerns especially the caption. Perhaps someone has a better solution. All this may be made easier by the hvfloat package.
murph636
Posts: 22
Joined: Sun Mar 15, 2009 3:54 am

Re: page numbering on multiple documents

Post by murph636 »

Thank you! That fixed my caption issues, now I just need to figure out why the table gets stretched out and hangs off the margin. Hopefully someone can help with that, then I will have all the bugs fixed for my final thesis draft!
Post Reply