Graphics, Figures & Tables ⇒ Rotate a table and should not move it to next page (PDF screen shot attached)
Rotate a table and should not move it to next page (PDF screen shot attached)
Please see the attachment and give me a solution to rotate the table and not move it to next page.
- Attachments
-
- Appendix_screenshot.png (273.57 KiB) Viewed 11471 times
NEW: TikZ book now 40% off at Amazon.com for a short time.

- Stefan Kottwitz
- Site Admin
- Posts: 10341
- Joined: Mon Mar 10, 2008 9:44 pm
Rotate a table and should not move it to next page (PDF screen shot attached)
You could use this:
Stefan
Code: Select all
\usepackage{rotating}
\begin{document}
...
\begin{sidewaystable}
\centering
\caption{Your table caption}
\begin{tabular}{...}
...
\end{tabular}
\end{sidewaystable}
LaTeX.org admin
Rotate a table and should not move it to next page (PDF screen shot attached)
I did add the code as you told. The good part is that table is rotated. BUt, it still appeared in second page by keeping the first page blank. Please, check the attached PDF screen shot.
- Attachments
-
- rotateerror.png (135.17 KiB) Viewed 11450 times
- Stefan Kottwitz
- Site Admin
- Posts: 10341
- Joined: Mon Mar 10, 2008 9:44 pm
Rotate a table and should not move it to next page (PDF screen shot attached)
Or rotate this way:
\end{document}[/code]
Stefan
Code: Select all
\usepackage[graphicx]{realboxes}
\usepackage{varwidth}
...
\begin{document}
...
\begin{table}[!htbp]
\centering
\rotatebox{90}{%
\begin{varwidth}{\textheight}
\caption{the caption text}\label{tab:1}
\begin{tabular}{...}
...
\end{tabular}
\end{varwidth}}
\end{table}
Stefan
LaTeX.org admin
Rotate a table and should not move it to next page (PDF screen shot attached)
Sorry. It did not work at all.
I added those two packages mentioned by you and Here is the code I entered:
I added those two packages mentioned by you and Here is the code I entered:
\begin{table}[!htbp] \centering \rotatebox{90}{% \begin{varwidth}{\textheight} \caption{Switch comparison} \begin{tabular}{|c|c|c|c|c|c|} \hline \multirow{2}{*}{Particulars} & \multicolumn{5}{c|}{per unit} \\ \cline{2-6} & IGBT\cite{igbt}& \gls{spst} \cite{spstdpst} & \gls{spdt} \cite{digikey} & \gls{dpst}\cite{spstdpst} & \gls{dpdt}\cite{dpdt} \\ \hline Size(in mm)&20x16x5&10x7x5&18x14 $\times$ 15&20x10x11&29x25x13 \\ \hline AC Rating & 1200V, 5A & 250V,5A & 250V,5A & 250V,5A&250V,5A \\ \hline \begin{tabular}[c]{@{}c@{}}Conduction loss \\ P$_{con}$ (in W)\end{tabular} & \begin{tabular}[c]{@{}c@{}}13.5$^{**}$\end{tabular} & 2.5&2.5&2.5&2.5 \\ \hline \begin{tabular}[c]{@{}c@{}}Gate loss \\ P$_{gate}$ (in W)\end{tabular} & \begin{tabular}[c]{@{}c@{}}DNA\end{tabular} & 0.75&0.4&0.75&0.54 \\ \hline %\begin{tabular}[c]{@{}c@{}}Perday loss(Whr)$^*$\end{tabular} & 130.5&25& 13.4 \\ \hline %\begin{tabular}[c]{@{}c@{}}Switching time($T_{on}$+$T_{off}$)\end{tabular}& 1.8+2.0= 3.8$\mu$s &3.3ms & 6+4=10ms \\ \hline \begin{tabular}[c]{@{}c@{}}Switching time\end{tabular}& 3.8$\mu$s &3.3ms& 10ms &5ms&15ms \\ \hline Elect. cycles &-&3x10$^4$& 10$^5$& 3x10$^4$& 10$^5$ \\ \hline Mech. cycles & -& 10$^7$ & 5x10$^6$& 10$^7$& 10$^7$ \\ \hline Operating temp. & $+150^{\circ}$C &\begin{tabular}[c]{@{}c@{}} -40 - +$85^{\circ}$C \end{tabular} &\begin{tabular}[c]{@{}c@{}} -40 - +$70^{\circ}$C \end{tabular} &\begin{tabular}[c]{@{}c@{}} -40 - +$85^{\circ}$C \end{tabular} &\begin{tabular}[c]{@{}c@{}} -30 - +$70^{\circ}$C \end{tabular} \\ \hline \begin{tabular}[c]{@{}c@{}}market cost (in \$) \end{tabular} & 30.38 &3.59 & 2.05 &3.59&3.77\\ \hline \end{tabular} %} \\ ~~**~$I_{CE}$=5A,$V_{CE}$=2.7V;DNA Data not available; %\end{sidewaystable} \end{varwidth}} \end{table}
- Stefan Kottwitz
- Site Admin
- Posts: 10341
- Joined: Mon Mar 10, 2008 9:44 pm
Rotate a table and should not move it to next page (PDF screen shot attached)
You could use a minipage instead of varwidth. Choose the height as option, as it fits. I used
Stefan
0.9\textheight
.Code: Select all
text
\begin{table}[!htbp]
\centering
\rotatebox{90}{%
\begin{minipage}{0.9\textheight}
\caption{Switch comparison}
\begin{tabular}{|c|c|c|c|c|c|}
...
\end{tabular}
\end{minipage}}
\end{table}
text
LaTeX.org admin
Rotate a table and should not move it to next page (PDF screen shot attached)
Excellent. Thanks a ton Stefan. It worked for me. Please, find the screen shot.
- Attachments
-
- tableDONE.png (85.78 KiB) Viewed 11407 times
- Stefan Kottwitz
- Site Admin
- Posts: 10341
- Joined: Mon Mar 10, 2008 9:44 pm
Rotate a table and should not move it to next page (PDF screen shot attached)
The 
Stefan
varwidth
environment was for auto-adjusting the width (here: hight, as it's rotated), somehow it did not work with the content here. But as it works with minipage
, fine. 
Stefan
LaTeX.org admin