The ANOM Procedure


Formatting Values and Customizing Labels

Note: See Formatting and Positioning the Inset on an ANOM Chart in the SAS/QC Sample Library.

By default, each inset statistic is identified with an appropriate label, and each numeric value is printed using an appropriate format. However, you may want to provide your own labels and formats. For example, in Figure 4.28 the default format used for the MSE prints an excessive number of decimal places. In the inset produced by the following statements, the unwanted decimal places are eliminated and the default MSE label is replaced by one specified by the user:

title 'ANOM Chart for Label Deviations';
proc anom data=LabelDeviations;
   xchart Deviation*Position / odstitle=title;
   inset mse='Mean Square Error' (7.5) nout;
run;

The resulting ANOM chart is displayed in Figure 4.29. You can provide your own label by specifying the keyword for that statistic followed by an equal sign (=) and the label in quotes. The label can have up to 24 characters.

The format 7.5 specified in parentheses after the MSE keyword displays the statistic with a field width of seven and five decimal places. In general, you can specify any numeric SAS format in parentheses after an inset keyword. You can also specify a format to be used for all the statistics in the INSET statement with the FORMAT= option (see Figure 4.30). For more information about SAS formats, refer to SAS Formats and Informats: Reference.

Note that if you specify both a label and a format for a statistic, the label must appear before the format.

Figure 4.29: Formatting Values and Customizing Labels in an Inset

Formatting Values and Customizing Labels in an Inset