Frank E Harrell Jr
2009-Jun-25 18:53 UTC
[R] LaTeX references inside R code using SweaveListingUtils
I have sent a note to Peter Ruckdeschel who wrote the excellent SweaveListingUtils package but find myself up against a deadline in preparing a handout for useR! 2009. The following is supposed to work: <<>>plot(x, y) # Figure `\ref{myfig}` @ Where the back tick ` is an escape character and \ref{myfig} will be replaced by LaTeX with the correct figure number that was created by a \label{myfig} command. I have not been able to get this to work. I just get `\ref{myfig}` verbatim on the R output. Does anyone know of a way to do this? Thanks Frank -- Frank E Harrell Jr Professor and Chair School of Medicine Department of Biostatistics Vanderbilt University