Hi: I'm using APA6 to prepare an article. I'm trying to get a centered caption to work, but none of the following variations on the theme work. The APA 6 documentation states that the caption package is loaded automatically and that there's an additional command `\centeredcaption'. I can't get either to work.
Thoughts?
\documentclass[doc]{apa6}
\usepackage[center]{caption}
\shorttitle{Test}
\begin{document}
\begin{table}
\caption{This is my caption}
\begin{tabular}{lrr}
This is my table & 5&10\\
This is my table & 5&10\\
\end{tabular}
\end{table}
\end{document}
\documentclass[doc]{apa6}
\shorttitle{Test}
\begin{document}
\begin{table}
\centeredcaption{5in}{This is my caption}
\begin{tabular}{lrr}
This is my table & 5&10\\
This is my table & 5&10\\
\end{tabular}
\end{table}
\end{document}
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
\documentclass[doc]{apa6}
\usepackage[justification=centering]{caption}
\shorttitle{Test}
\begin{document}
\begin{table}
\caption{This is my caption}
\begin{tabular}{lrr}
This is my table & 5&10\\
This is my table & 5&10\\
\end{tabular}
\end{table}
\end{document}
For details please have a look at the documentation: caption.
sjkiss wrote:Hi Clemens, thanks for that. I just tried your code, but it didn't work. I got an option clash error message "option clash for package caption".
Hi Clemens,
I see the \captionsetup command in the caption documentation, but I wasn't aware that it could be used without invoking the \usepackage{caption}. But I guess if APA is loading the caption package silently (as the documentation seems to suggest), then it seems like it's not necessary. Is that right?
One other question though. I can't seem to get upright captiontext with the following code. The documentation has this to say:
font= There are three font options which affects different parts of the caption: ). You set them
up using the options
font={hfont optionsi} ,
labelfont={hfont optionsi} , and
textfont={hfont optionsi} ,
where hfont optionsi is a list of comma separated font options.
And these are the available font options:
scriptsize Very small size
footnotesize The size usually used for footnotes
small Small size
normalsize Normal size
large Large size
Large Even larger size up Upright shape
\documentclass[doc]{apa6}
\shorttitle{test}
\captionsetup{justification=centering, textfont=up}
\begin{document}
\begin{table}
\caption{This is my caption}
\begin{tabular}{lrr}
This is my table & 5&10\\
This is my table & 5&10\\
\end{tabular}
\end{table}
\end{document}
Last edited by cgnieder on Thu Aug 30, 2012 6:07 pm, edited 1 time in total.
sjkiss wrote:Hi Clemens,
I see the \captionsetup command in the caption documentation, but I wasn't aware that it could be used without invoking the \usepackage{caption}. But I guess if APA is loading the caption package silently (as the documentation seems to suggest), then it seems like it's not necessary. Is that right?
In short: yes. Actually it not only loads caption but also defines setup's for the captions. You need to redefine the setup that's used for the table caption text:
\documentclass[doc]{apa6}
\shorttitle{test}
\captionsetup{justification=centering}
\DeclareCaptionTextFormat{tabletext}{\hspace{-\parindent}#1}% same as the one by apa6 but without \textit
\begin{document}
\begin{table}
\caption{This is my caption}
\begin{tabular}{lrr}
This is my table & 5&10\\
This is my table & 5&10\\
\end{tabular}
\end{table}
\end{document}
OK, Yours works, but I don't understand why mine doesn't work. I tried playing with the version below. It should work, shouldn't it? and where do you get the label "tabletext" from?
Hi there:
I'm not sure if you're reading this Clemens, or anyone else, but I'm still working with this.
The problem still remains: I can't combine sans serif with small caps. It seems like sans serif works, and all the other font options listed in the caption package documentation work just fine, but combining small caps with sans serif just doesn't work.
Help!
Simon
\documentclass[doc, natbib]{apa6}
\usepackage{graphicx}
\usepackage{dcolumn}
\newcommand{\thickhline}{\noalign{\hrule height 1.5pt}}
\captionsetup{justification=centering, labelfont={sf,sc}, labelsep=newline}
\usepackage[figuresright]{rotating}
\title{Sustaining Agendas: Assessing The Media's Role In the Regulation of Bisphenol A In The US States}
\shorttitle{Sustaining Agendas}
\affiliation{Journalism Program\\Wilfrid Laurier University}
\author{Simon J. Kiss}
\begin{document}
This is my document
\begin{table}
\center
\caption{Exposure Estimates To BPA}
\begin{tabular*}{0.9\textwidth}{lc}
\thickhline
Age Category & micrograms/kg/bw per day\\
\hline
0-4 month-old infant & 1.6 \\
6-12 month-old infant & 0.8\\
4-6 year old child & 1.2 \\
60 kg adult & 0.37 \\
\thickhline
\multicolumn{2}{l}{\emph{Source:} European Commission. Scientific Committee on Food. (2002)}\\
\end{tabular*}
\end{table}
\end{document}
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p