I am making a beamer presentation, I have a problem with the caption of a table and for the figures: they are not numbered... why?
Could anyone please help me?
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[12pt, compress]{beamer}
\usepackage{beamerthemeshadow}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath,amssymb,amsfonts}
\usepackage[round]{natbib}
%\newcommand{\newblock}{}%JB: Already defined
\usepackage[font=scriptsize]{caption}
\usetheme{Warsaw}
\usecolortheme[named=purple]{structure}
\begin{document}
\setbeamerfont{frametitle}{size=\small,
%labelfont=bf%JB: Undefinded
}
\setbeamertemplate{caption}[numbered]
\begin{frame}
\frametitle{Introduction}
\begin{table}[h]%Why the placement specifier?
\captionof{table}{TABLE NAME}
% \begin{center}%JB: use
\centering
%instead
\begin{tabular}{|c|c|}
\hline
A & B \\
\hline
C & D \\
\hline
\end{tabular}
% \end{center}
\end{table}
\end{frame}
\begin{frame}
\frametitle{Electrophysiology of the heart}
\begin{figure}[h]%Why the placement specifier?
% \begin{center}%JB: use
\centering
%instead
\includegraphics[width=.7\textwidth]{example-image}
\caption{... }
%JB the other one gave me an error
Reproduced from \citep{malmivuo1995bioelectromagnetism}
% \end{center}
\end{figure}
\end{frame}
\end{document}
Why do you need captions in a presentation? You don't need to refer to them, you can oint on them and tell what's going on in the picture.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Running exactly your code I got no numbered table even picture, please see the uploaded attachment ... (sorry for the picture size!) I am missing something?
Screen Shot 2014-08-08 at 16.19.25.png (98.4 KiB) Viewed 14849 times
Running exactly my code i get the same result as i have when clicking on »open in wirtelatex« just above my code. Please do so as well and try to figure out any any differences. I really need to hear back from you, cause either you had a really bad day, or i did.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
You said you ran my code exactely, which i did not (and still don't) believe you. Please click on »Open in writelatex« just above the code box in one of my previous posts to really run the code i gave you. Apart from the captions, there is one big difference.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
The editor is not relevant. Perhaps you have an older version of the beamer package, if your version does not what Johannes' version and writeLaTeX does. In that case you could update, possibly your whole TeX installation so all would be up to date.
So it's a compatibility issue with caption and beamer. I remember it from some time ago, beamer had its own caption features and it did not work together. The authors should have fixed it.
So you can work without caption, or update to use both later together. I think it's solved now?
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