r/LaTeX•
Taurashvn

Reference a figure that does not possess a caption/workaround for invisible caption

Answered

Hello,

I am trying to reference a figure that cannot have a caption. A snippet of the figure looks like this:

\begin{figure}[tb]
\centering
\begin{subfigure}[t]{0.03\textwidth}
\textbf{a}
\end{subfigure}
\begin{subfigure}[t]{0.45\linewidth}
\includegraphics[width=\linewidth,valign=t]{Graphs/Glucose/OD_glucose_whi7-ko.png}
\label{Fig:Whi7OD}
\end{subfigure}

Compiles as such

However, the a at the top left is not a caption, rather just text. Hence, when I try to \cref the figure, it is referenced to as a section instead of a figure.

I have tried adding invisible captions with \caption* and \caption{phantom}, but neither of the workarounds worked.

Does anyone have any workarounds for this? Can I achieve the same result in a different way?

Posted May 4, 2025, 4:41 PM UTC

35
Loading comments…