我正在尝试制作一个包含超过 26 个子图的图形,因此,字母表的计数器不够,因为它只到 z。我按照其他帖子中的建议尝试使用 alphalph 包,如下所示:
\documentclass[smallextended]{svjour3}
\usepackage{graphics,graphicx,color}
\usepackage{subfigure}
\usepackage{alphalph}
\usepackage{psfrag,epsfig}
\renewcommand{\thesubfigure}{\alphalph{subfigure}}
\begin{document}
\begin{figure}
\centering
\subfigure[]{\includegraphics[width=0.23\columnwidth]{figures/Segmentation/Pedestrians_trck.eps}\label{fig:a_trck}}
\subfigure[]{\includegraphics[width=0.23\columnwidth]{figures/Segmentation/Pedestrians_segm.eps}\label{fig:a_segm}}
\subfigure[]{\includegraphics[width=0.23\columnwidth]{figures/Segmentation/Pedestrians_SOBS.eps}\label{fig:a_SOBS}}
%and so on until 32 subfigures
\caption{Segmentation performance}
\label{fig:pedestrians}
\end{figure}
\end{document}
但是,对于文档中的其他数字(未自动枚举),我收到此错误:“缺失数字视为零”。
其余数字声明如下:
\begin{figure}[!h]
\centering
\subfigure[\scriptsize{distribution with heavy tails}]{\includegraphics[width=.48\columnwidth]{Figures/Theory/PDF1n}\label{fig:PDF1}}
\subfigure[\scriptsize{distribution with light tails}]{\label{fig:PDF2}
\includegraphics[width=.48\columnwidth]{Figures/Theory/PDF2n}}
\caption{\scriptsize{Kernel bandwidth selection strategy}}.
\end{figure}
答案1
\alphalph
需要一个计数器值作为参数。但是包subfigure
已过时,请subfig
改用:
\documentclass[smallextended]{svjour3}
\usepackage[demo]{graphicx}% delete [demo] after testing
\usepackage{subfig}
\usepackage{alphalph}
\renewcommand\thesubfigure{\alphalph{\value{subfigure}}}
\begin{document}
\begin{figure}
\centering
\subfloat[]{\includegraphics[width=0.23\columnwidth] {figures/Segmentation/Pedestrians_trck.eps}\label{fig:a_trck}}
\subfloat[]{\includegraphics[width=0.23\columnwidth]{figures/Segmentation/Pedestrians_segm.eps}\label{fig:a_segm}}
\subfloat[]{\includegraphics[width=0.23\columnwidth]{figures/Segmentation/Pedestrians_SOBS.eps}\label{fig:a_SOBS}}
\caption{Segmentation performance}
\label{fig:pedestrians}
\end{figure}
\end{document}