Re: math in graph title [message #53976] |
Wed, 09 May 2007 15:40 |
Christopher Thom
Messages: 66 Registered: October 2006
|
Member |
|
|
Quoth Benjamin Hornberger:
> kostis wrote:
>> How can I write a mathematical expression in a plot title
>> with superscripts and subscripts appearing the right way?
>>
>> Unfortunately: TITLE='x^2' produces x^2
>>
>
> If you know LaTeX, you can use the TeXtoIDL package (search Google for it).
urgh! For some reason, I *always* forget about this, even though I have it
installed...I've been dragging my heels for two days setting up my axis
labels correctly. Thanks for the mental push :)
cheers
chris
|
|
|
Re: math in graph title [message #53978 is a reply to message #53976] |
Wed, 09 May 2007 11:29  |
Benjamin Hornberger
Messages: 258 Registered: March 2004
|
Senior Member |
|
|
kostis wrote:
> How can I write a mathematical expression in a plot title
> with superscripts and subscripts appearing the right way?
>
> Unfortunately: TITLE='x^2' produces x^2
>
If you know LaTeX, you can use the TeXtoIDL package (search Google for
it). Otherwise, you have to use embedded formatting commands. Go to
"fonts" -> "positioning commands" in the IDL help index. For example,
IDL> plot, findgen(10), title='x!e2!x'
produces what you where asking for.
Good luck,
Benjamin
|
|
|