Xmgrace is a very nice piece of software to create publication quality figures. Even better is that it stores your data and graph layout options as plain text (which is especially nice in combination with subversion or scripts to edit your graph).
But some things are not very intuitive, which is why I keep a list of some useful possibilities below:
- Subscript, superscript
- Greek letters, example: theta
\xq\0qto get a theta symbol followed by the letter q: \x switches to the Symbol font and \0 switches back to Times-Roman.
- Special symbols, example: Angstrom symbol
For other characters, look at this list: ascii table with low and high characters. Just use the character from the left column between \c and \C to produce the one from the right column. I highlighted the most interesting characters (for a scientist). The \c and \C option are listed as deprecated in the xmgrace manual.
, but what is the new way?.The new method to insert special characters in xmgrace is:
- Press ctrl-e while positioned in a text-edit field to bring up the font dialog box.
- Select the desired font from the drop-down list. You probably want to use Symbol because it contains many of the commonly used special characters.
- Click on the character you want to insert
- Saving the default settings for new graphs:
open xmgrace, make the desired settings, save them as:
Unfortunately, this does not save the "print" settings, but see below.
- Setting the default printer to print to .png files with 300dpi:
create the file
~/.grace/gracerc.userand enter the following text:
HARDCOPY DEVICE "PNG"
DEVICE "PNG" DPI 300
- Changing the definition of the default colors:
Just edit the lines that say
@map color 7 to (220, 220, 220), "grey"
in the saved file. Edit the default file (see above) if you wish to use the new colors everywhere from now on.
If you have more helpful hints, please post them in the comments, so that this blog post will become an interesting collection of tips that can be turned into a useful "cheat sheet".