2
$\begingroup$

I have a plot and I would like to annotate some mathematical text in it. Initially, Mathematica puts it in italics by using Drawing tools palette, but I want it all in plain text. How can I do it? Thanks for your time.

$\endgroup$
2

2 Answers 2

3
$\begingroup$

If you want to use the Drawing tools and annotate by hand, the palette offers standard format options out of the box. Just choose your font, font size etc.:

Mathematica graphics

$\endgroup$
1
  • $\begingroup$ As Verbeia says, that solution will fail if I want to re-evaluate my plot. Thanks. $\endgroup$ Oct 12, 2012 at 11:14
3
$\begingroup$

Yves' answer is perfect if you are never going to re-evaluate your plot, for example because the data have been updated. Annotations drawn with the drawing tools are not part of the plot definition code and so are not included if you re-evaluate it.

It is not 100% clear from your question, but I think you are being stung by the same thing I was: typeset mathematical expressions italicize in ways you might not want.

See if the accepted answer to my earlier question solves your problem.

By default Mathematica typesets mathematical expressions inside a Text expression. It does not italicize standard function names like $\sin$, but it does for single-letter symbols. Notice that I have placed the text using Epilog. It is a good function to get to know, along with Prolog and Inset.

Plot[Sin[x], {x, 0, 4 Pi}, BaseStyle -> {FontSize -> 14}, 
 Epilog -> {Text[Sin[x], {5, 0.5}]}]

enter image description here

If you want to turn off the italicization of $x$, then use the FormatType option as described in Albert's answer to my question linked above.

$\endgroup$
1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.