I want to insert a non floating table with a caption above.
So I included the caption package and added my table:
\usepackage{caption}
...
\begin{center}
\captionof{table}{Kurvenparameter zur Parametrierung des Spulenstroms}
\label{tab_kurvenparameter}
\begin{tabularx}{\columnwidth}{lllX}
\toprule
... table content
\bottomrule
\end{tabularx}
\end{center}
The problem now: the table is to big for the rest of the page so it is placed on the next page. But the caption remains on the previuos page. So now my question is: How can I glue caption and table together?
You can warp the whole thing in a minipage:
\documentclass{article}
\usepackage{tabularx}
\usepackage{booktabs}
\usepackage{caption}
\begin{document}
\begin{minipage}{\linewidth}
\centering
\captionof{table}{Kurvenparameter zur Parametrierung des Spulenstroms}
\label{tab_kurvenparameter}
\begin{tabularx}{\columnwidth}{lllX}
\toprule
... table content\\
\bottomrule
\end{tabularx}
\end{minipage}
\end{document}
Related
I'm trying to align a subfigure and a subtable and I found the following solution. Captions are aligned only if they have the same number of lines. Table caption is aligned at the bottom of the figure caption and changing [b] to [t] doesn't resolve the issue. How can I have the captions aligned at the top?
\documentclass[twocolumn]{article}
\usepackage[demo]{graphicx}
\usepackage{subcaption}
\begin{document}
\begin{figure*}[!h]
\centering
\begin{subfigure}[b]{0.48\textwidth}
\includegraphics[width=1.0\linewidth]{figure.png}
\caption{Caption 1 : this one is a very long two lines caption and is misaligned}
\label{fig:fig1}
\end{subfigure}
%
\begin{subtable}[b]{0.48\textwidth}
\centering
\begin{tabular}{|c|c|}
1 & 2\\ \hline
11 & 22\\ \hline
\end{tabular}
\caption{Caption 2}
\label{table:table}
\end{subtable}
\caption{Caption 3}
\label{fig:mainfigure}
\end{figure*}
\end{document}
there is extra space between the words of the footnotes in the figure below. How can I fix this issue?
\documentclass[jou]{apa7}
\begin{document}
\begin{figure*}
\centering
\caption{Title}
\vspace{0.3cm}
\includegraphics[width=\textwidth]{example.png}
\vspace{4pt}
\begin{tablenotes}[para,flushleft]
{\small \textit{Note.} Figure notes here }
\end{tablenotes}
\end{figure*}
\end{document}
Your table note tries to fill the whole line. To avoid the extra space you can add \hfill at the end to fill the line.
\documentclass[jou]{apa7}
\shorttitle{subtitle}
\begin{document}
\begin{figure*}
\centering
\caption{Title}
\vspace{0.3cm}
\includegraphics[width=\textwidth]{example-image-duck}
\vspace{4pt}
\begin{tablenotes}[para,flushleft]
{\small \textit{Note.} Figure notes here\hfill }
\end{tablenotes}
\end{figure*}
\end{document}
I have a table with 3 columns where the first 2 columns are pictures and the 3rd is my comment on those pictures, but the comment "drowns", it is down at the bottom of the cell.
I have tried with m{2cm} instead of c:
\begin{tabularx}{\textwidth}{c c m{2cm}}
but no change.
\begin{table}
\caption{Caption if needed}
\label{tab:lastcheck}
\begin{tabularx}{\textwidth}{c c c}
\textbf{O-Na} & \textbf{Na-Y} & \textbf{Comments} \\
\includegraphics[width=0.3\linewidth]{pic1.png} &
\includegraphics[width=0.3\linewidth]{pic2.png} &
My comments. \\
\end{tabularx}
\end{table}
My text is at the bottom of the cell.
The graphbox provides the handy align=c option to vertically centre images:
\documentclass{article}
\usepackage{tabularx}
\usepackage{array}
\usepackage{graphicx}
\usepackage{graphbox}
\usepackage{makecell}
\renewcommand\theadfont{\bfseries}
\begin{document}
\begin{table}
\caption{Caption if needed}
\label{tab:lastcheck}
\begin{tabularx}{\textwidth}{XXX}
\thead{O-Na} & \thead{Na-Y} & \thead{Comments} \\
\includegraphics[width=\linewidth,align=c]{example-image-duck} &
\includegraphics[width=\linewidth,align=c]{example-image-duck} &
My comments. \\
\end{tabularx}
\end{table}
\end{document}
I'm writing a paper in Spanish, and I need the name of my tables as "Tabla," not as "Cuadro" which is the current name.
I used the command:
\renewcommand{\tablename}{Tabla}
But it is not working, as nothing changes. I do not have any error when compiling, and the name of my table is still "Cuadro".
\documentclass[journal]{IEEEtran}
\usepackage[utf8]{inputenc}
\usepackage[spanish, english]{babel}
\usepackage{graphicx}
\usepackage{amsmath}
\spanishdecimal{.}
\begin{document}
\renewcommand{\tablename}{Tabla}
\newcommand\Tstrut{\rule{0pt}{2.6ex}}
\newcommand\Bstrut{\rule[-0.9ex]{0pt}{0pt}}
\begin{table}[h!]
\begin{center}
\caption{Title}
\label{label1}
\centering
\begin{tabular}{c}
\hline \rule[-1ex]{0pt}{2.5ex}something A \Tstrut\Bstrut\\
\rule[-1ex]{0pt}{2.5ex} Something B \Tstrut\Bstrut \\
\rule[-1ex]{0pt}{2.5ex}Something C\Tstrut\Bstrut \\
\hline
\end{tabular}
\end{center}
\end{table}
\end{document}
There is a special option es-tabla for the babel package.
Some other points:
if the main language of your document is Spanish, this should be the last language loaded in the options of the babel package, e.g. after english
the floating specifier [h!] is almost a guarantee for bad image placement, better use something like [htbp]
\documentclass[journal]{IEEEtran}
\usepackage[utf8]{inputenc}
\usepackage[english,spanish,es-tabla]{babel}
\usepackage{graphicx}
\usepackage{amsmath}
\spanishdecimal{.}
\newcommand\Tstrut{\rule{0pt}{2.6ex}}
\newcommand\Bstrut{\rule[-0.9ex]{0pt}{0pt}}
\begin{document}
\begin{table}[htbp]
\begin{center}
\caption{Title}
\label{label1}
\centering
\begin{tabular}{c}
\hline \rule[-1ex]{0pt}{2.5ex}something A \Tstrut\Bstrut\\
\rule[-1ex]{0pt}{2.5ex} Something B \Tstrut\Bstrut \\
\rule[-1ex]{0pt}{2.5ex}Something C\Tstrut\Bstrut \\
\hline
\end{tabular}
\end{center}
\end{table}
\end{document}
How can I rotate a page 180 degrees in LaTeX?
\usepackage{lscape}
\begin{landscape}
Some text
\end{landscape}
Or for the whole document:
\documentclass[landscape]{article}
Edit: This would of course only rotate the page by 90°... Sorry. ;)
Have you tried the rotating package?
See http://en.wikibooks.org/wiki/LaTeX/Packages/Rotating
This would rotate the content you put between begin and end. Do you need a designated page to be rotated you can achieve it using \newpage and \clearpage.:
To answer your question in the comments, I don't know how to achieve this within one single environment if you are going to use different types of content (text, images...) within the turn environment. That depends a lot on what you exactly want to achieve.
\documentclass{article}
\usepackage{rotating}
\title{Test document}
\author{Wesho}
\date{18/06/2009}
\begin{document}
\maketitle
\newpage
\begin{rotate}{180}
\includegraphics{graphic.pdf}
\end{rotate}
\clearpage
\end{document}
It depends on the task, but \rotatebox{180} together with \minipage can do the job:
\documentclass[a4paper,12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage{rotating}
\usepackage{lipsum}
\begin{document}
\lipsum[1-3]
\newpage
\noindent\rotatebox{180}{\noindent\begin{minipage}{\textwidth}
\lipsum[1]
\begin{center}\includegraphics{image01.jpg}\end{center}
\lipsum[2]
\begin{center}
\begin{tabular}{cc}
\hline
1 & 2 \\
3 & 4 \\
\hline
\end{tabular}
\end{center}
\lipsum[3]
\end{minipage}}
\clearpage
\lipsum[1-3]
\end{document}