I am using, and really liking markstat by German Rodriguez to write a short paper. One issue that emerged and that I haven't been able to solve nor found a description for on German's site is how to cross-reference to figures (or tables) throughout the document.

I want to produce a pdf so the first approach that I have tried is to use some latex syntax of the form:

Code:
\begin{figure}
  \centering
  \includegraphics[]{graph1}
  \caption{my caption}
  \label{my label}
\end{figure}
Then I try to insert the label in the text calling
Code:
\ref{my label}
Unfortunately, latex does not seem to recognize the cross-reference and shows instead ?? where the label should be.

I looked in the markstat documentation and I could not find a way to label a graph using the usual markstat syntax to include graphs:
Code:
![My caption](graph1)
Am I missing something? Shouldn't the latex syntax work? Should I look into how Pandoc handles cross-references instead?

Thanks for your answers.