What is Grace?

Grace (formerly Xmgr) is a WYSIWYG two-dimensional plotting tool for numerical data using X. It has a convenient interactive GUI interface. Its strength lies in the fact that it combines the convenience of a graphical user interface with the power of a scripting language which enables it to do sophisticated calculations or perform automated tasks.
Screenshots (click to enlarge)

Using Grace

  1. Start the GUI interface, type: xmgrace &
  2. Select/check the output medium and canvas size in File/Device Setup.
  3. If needed, set the graph size (‘Viewport’ in Plot/Graph Appearance).
  4. Load your data with Data/Import/ASCII. ‘Load as”: ‘Single set’ for two-column ASCII data, ‘Block data’ for multi-column ASCII data.
  5. Adjust the scales, axis labels and tick marks in Plot/Axis properties. Acknowledge all changes with ‘Apply’.
  6. Adjust lines, symbols, legends in Plot/Set appearance.
  7. Adjust titles, plot frame and legend display in Plot/Graph Appearance.
  8. Data can be manipulated in Data/Transformations. To shift a data set by 20 to the left, e.g., in ‘Evaluate Expression’ select the same set on the left and the right, and say Formula: y=y-20. As you’ll probably notice, Grace can do MUCH more than that. Explore at your leisure.
  9. When you like your plot, select File/Print. That’s it!

On hpc2015, one may use the following commands to load xmgrace into the environment:

export GRACE_HOME=/share1/grace/5.1.25/grace
export PATH=${GRACE_HOME}/bin:$PATH

To run xmgrace demos, type the follow (in X environment):

$GRACE_HOME/examples/dotest &

This launches Grace with an interactive session. When you exit from one session another interactive session is launched which explains the next topic. On hpc2015 you have to “cd” to $GRACE_HOME/examples first.

Additional Information

Grace Home Page
Grace User Guide
Grace Tutorial