[Tex/LaTex] Sideways table cut off

rotating

I'm trying to create a sideways table with the informs3 class. After running pdflatex the table is cut off at the top and not properly centered on the page. If I change the document class the sideways table looks fine. What seems to be the problem? The code is provided below.

Many thanks

\documentclass[trsc,nonblindrev]{informs3}
\usepackage{rotating,booktabs}
....
....
\begin{sidewaystable} 

\caption{Comparison between the best solutions obtained with BLS and MGCH, in terms of the individual  GAP objectives.  }
\medskip
\scriptsize \centering

\begin{tabular}{p{5cm} | c c  | c c | c c | c c | c c | c c}
\hline
Objective  & \multicolumn{2}{c}{\underline{$D_1$}} & \multicolumn{2}{c}{\underline{$D_2$}}&\multicolumn{2}{c}{\underline{$D_3$}} & \multicolumn{2}{c}{\underline{$D_4$}} & \multicolumn{2}{c}{\underline{$D_5$}} & \multicolumn{2}{c}{\underline{$D_6$}}\\

 & BLS & MGCH & BLS & MGCH & BLS & MGCH & BLS & MGCH & BLS & MGCH & BLS & MGCH \\
\hline
Min.(avg.) idle time bewteen activities at the same gate (in min.) &    10(212.7) & 10(212.3) & \textbf{15}(199.6) &    10(163.7) & \textbf{15}(193.6) & 10(182.3) & \textbf{15}(192.0) &10(175.3)   & 10(175.1) &  10(144.9) & 10(177.6) & 10(161.2) \\
Min.(avg.) idle time bewteen activities at shadowing gates (in min.) &  20(503.9) & \textbf{25}(607.8)  & 40(419.7) &   40(422.8) & \textbf{45}(458.4) & 15(363.7) &    \textbf{30}(789.1) & 15(517.6) & 20(342.9) & 20(368.2) & \textbf{20}(412.9) & 10(411.9) \\
Min.(avg.) idle time bewteen activities at the same gate group (in min.) & \textbf{5}(93.4) & 0(91.6) & \textbf{5}(85.7) &  0(59.2) & \textbf{5}(81.4) & 0(76.7) & \textbf{5}(85.5) & 0(65.5) & \textbf{5}(69.6) & 0(56.8) & \textbf{5}(83.3) & 0(76.9) \\

\hline
 \end{tabular} \label{objective values}

\begin{tabular}{c | c c  | c c | c c | c c | c c | c c}
\hline
 Objective  & \multicolumn{2}{c}{\underline{$D_{1to6}$}} & \multicolumn{2}{c}{\underline{$P0.87$}}&\multicolumn{2}{c}{\underline{$P.97$}} & \multicolumn{2}{c}{\underline{$P1.03$}} & \multicolumn{2}{c}{\underline{$P1.14$}} \\
 & BLS & MGCH & BLS & MGCH & BLS & MGCH & BLS & MGCH & BLS & MGCH  \\
\hline

Min.(avg.) idle time bewteen activities at the same gate (in min.) & 10 (321.6) & 10 (323.3) & 10 (204.9) & 10 (207.9) & \textbf{15} (209.8) &  10 (212.6) & 10 (208.8) & 10 (211.1) & 10 (203.9) & 10 (208.5) \\
Min.(avg.) idle time bewteen activities at shadowing gates (in min.) &  \textbf{15} (1633.7) & 10 (1453.3) & \textbf{25} (583.7) & 10 (554.9) & \textbf{20} (546.6) & 15 (534.2) &  \textbf{25} (491.9) & 15 (533.8) & \textbf{25} (489.3) &    10 (567.2) \\
Min.(avg.) idle time bewteen activities at the same gate group (in min.) &  \textbf{5} (65.1) & 0 (47.1) & \textbf{5} (94.6) &  0 (89.0) & \textbf{5} (80.9) &  0 (84.7) & \textbf{5} (99.5) &  0 (83.0) &  \textbf{5} (77.3) & 0 (79.9) \\

\hline
 \end{tabular} \label{objective values}
\end{sidewaystable}

Best Answer

You mention that the sideways-table is too big if you use the informs3 document class, but not if you use some other document class. (Incidentally, which other document class, or classes, did you try?)

However, I don't think the informs3 document class is to blame. The main changes you should implement to make the tables fit in the text block are

  • a reduction in the amount of inter-column white space (governed by the parameter \tabcolsep), say to 2pt (default value: 6pt), and

  • use of the p{...} column type for the first column of the second tabular environment. (Your posting uses the c type for that column.

With these changes in place, you can employ the \footnotesize font size directive, for a 20% linear reduction, instead of the more drastic \scriptsize (30% linear reduction) instruction you use in your posting.

In addition, in view of the fact that you're already loading the booktabs package, you might want to use that package's macros \toprule, \midrule\, \cmidrule, and \bottomrule instead of generic LaTeX \hline instruction. Using the \cmidrule directive, with left-hand and right-hand trimming as appropriate, also seems preferable to using \underline for multicolumn headers. (By the way, if you do make the switch to the line-drawing commands of the booktabs package, you should avoid drawing vertical rules.)

enter image description here

\documentclass[trsc,nonblindrev]{informs3}
\usepackage{rotating,booktabs}
\begin{document}
\begin{sidewaystable} 
\setlength\tabcolsep{2pt} % default value: 6pt
\footnotesize  % not `\scriptsize
\centering

\begin{tabular}{ @{} p{5cm} *{6}{cc} @{}}
\toprule
Objective  
& \multicolumn{2}{c}{$D_1$} & \multicolumn{2}{c}{$D_2$}
& \multicolumn{2}{c}{$D_3$} & \multicolumn{2}{c}{$D_4$}
& \multicolumn{2}{c}{$D_5$} & \multicolumn{2}{c}{$D_6$}\\
\cmidrule(lr){2-3} \cmidrule(lr){4-5} \cmidrule(lr){6-7}
\cmidrule(lr){8-9} \cmidrule(lr){10-11} \cmidrule(l){12-13}
& BLS & MGCH & BLS & MGCH 
& BLS & MGCH & BLS & MGCH 
& BLS & MGCH & BLS & MGCH \\
\midrule
Min.(avg.)\ idle time bewteen activities at the same gate (in min.) &    10(212.7) & 10(212.3) & \textbf{15}(199.6) &    10(163.7) & \textbf{15}(193.6) & 10(182.3) & \textbf{15}(192.0) &10(175.3)   & 10(175.1) &  10(144.9) & 10(177.6) & 10(161.2) \\
Min.(avg.)\ idle time bewteen activities at shadowing gates (in min.) &  20(503.9) & \textbf{25}(607.8)  & 40(419.7) &   40(422.8) & \textbf{45}(458.4) & 15(363.7) &    \textbf{30}(789.1) & 15(517.6) & 20(342.9) & 20(368.2) & \textbf{20}(412.9) & 10(411.9) \\
Min.(avg.)\ idle time bewteen activities at the same gate group (in min.) & \textbf{5}(93.4) & 0(91.6) & \textbf{5}(85.7) &  0(59.2) & \textbf{5}(81.4) & 0(76.7) & \textbf{5}(85.5) & 0(65.5) & \textbf{5}(69.6) & 0(56.8) & \textbf{5}(83.3) & 0(76.9) \\
\bottomrule
\end{tabular} 

\bigskip\bigskip % provide some separation between the tabular environments

\begin{tabular}{@{} p{5cm} *{5}{cc} @{}}
\toprule
 Objective  
& \multicolumn{2}{c}{$D_{1to6}$} & \multicolumn{2}{c}{$P0.87$}
& \multicolumn{2}{c}{$P.97$} & \multicolumn{2}{c}{$P1.03$} 
& \multicolumn{2}{c}{$P1.14$} \\
\cmidrule(lr){2-3} \cmidrule(lr){4-5} \cmidrule(lr){6-7}
\cmidrule(lr){8-9} \cmidrule(l){10-11}
& BLS & MGCH & BLS & MGCH & BLS & MGCH 
& BLS & MGCH & BLS & MGCH  \\
\midrule
Min.(avg.)\ idle time bewteen activities at the same gate (in min.) & 10 (321.6) & 10 (323.3) & 10 (204.9) & 10 (207.9) & \textbf{15} (209.8) &  10 (212.6) & 10 (208.8) & 10 (211.1) & 10 (203.9) & 10 (208.5) \\
Min.(avg.)\ idle time bewteen activities at shadowing gates (in min.) &  \textbf{15} (1633.7) & 10 (1453.3) & \textbf{25} (583.7) & 10 (554.9) & \textbf{20} (546.6) & 15 (534.2) &  \textbf{25} (491.9) & 15 (533.8) & \textbf{25} (489.3) &    10 (567.2) \\
Min.(avg.)\ idle time bewteen activities at the same gate group (in min.) &  \textbf{5} (65.1) & 0 (47.1) & \textbf{5} (94.6) &  0 (89.0) & \textbf{5} (80.9) &  0 (84.7) & \textbf{5} (99.5) &  0 (83.0) &  \textbf{5} (77.3) & 0 (79.9) \\
\bottomrule
\end{tabular}
%\caption{Comparison between the best solutions obtained with BLS and MGCH, in terms of the individual GAP objectives.}
%\label{objective values}

\end{sidewaystable}
\end{document}