Hallo,

I am using LyX with Sweave to directly access R in my LyX document.
This all works great but there is a tiny thing bugging me a lot:

There is the sweave LaTeX command \Sexpr{ foo } which allows you to
directly insert the content of foo into the document. Let's say there
is a variable foo_bar then I can access foo_bar by inserting an ERT
\Sexpr{foo_bar}. This works fine in text but NOT in math mode. It
always wants to escape the underscore to \Sexpr{foo_{b}ar} .

So how can I insert true raw ERT commands in math mode or is this
perhaps even not possible?

Thanks for your help!

Matthias

Reply via email to