The PARETO Procedure

HBAR Statement

HBAR (variable-list )</ options> ;

The HBAR statement creates a Pareto chart that uses horizontal bars to represent the frequencies of problems in a process or operation. The HBAR statement does not produce line printer charts, so you cannot specify it when you specify the LINEPRINTER option in the PROC PARETO statement.

A horizontal Pareto chart has a vertical category axis. The frequency axis appears at the top of the chart and measures the lengths of the bars on the chart. The cumulative percentage axis is at the bottom of the chart and measures the cumulative percentage curve.

The HBAR statement produces two types of output for Pareto charts:

  • It produces ODS Graphics output if ODS Graphics is enabled (for example, by specifying the ODS GRAPHICS ON statement prior to the PROC statement).

  • Otherwise, it produces traditional graphics if SAS/GRAPH is licensed.

For more information about producing these different types of graphs. see Chapter 3: SAS/QC Graphics,

The variable-list specifies the process variables to be analyzed. PROC PARETO creates a chart for each variable, and the values of each variable determine the Pareto categories for that chart. If variable-list contains only one process variable, you do not need to enclose it in parentheses.

The variables can be numeric or character, and the maximum length of a character variable is 64. Formatted values determine the categories and are displayed in labels and legends. The maximum format length is 64.

Table 15.3 lists the HBAR statement options by function. For complete descriptions, see the section Dictionary of HBAR and VBAR Statement Options.

Table 15.3: HBAR Statement Options

Option

Description

Data Processing Options

FREQ=

Specifies the frequency variable

MISSING

Requests that missing values of the process variable be treated as a Pareto category

MISSING1

Requests that missing values of the first CLASS= variable be analyzed as a level

MISSING2

Requests that missing values of the second CLASS= variable be analyzed as a level

OUT=

Creates an output data set that saves the information that is displayed in the Pareto chart

WEIGHT=

Specifies weight variables used to weight frequencies

Options for Restricting the Number of Categories

LOTHER=

Specifies a label for the OTHER= bar

MAXCMPCT=

Displays only the categories whose cumulative percentage is less than the specified percentage

MAXNCAT=

Displays only the categories that have the n highest values

MINPCT=

Displays only the categories whose percentages are greater than the specified percentage

OTHER=

Merges all categories that are not displayed

OTHERCVAL=

Specifies an OUT= data set character variable value for the OTHER= category

OTHERNVAL=

Specifies an OUT= data set numeric variable value for the OTHER= category

Options for Displaying Bars

BARLABEL=

Displays labels for bars

BARS=

Specifies a variable that groups bars for a display by using ODS style colors

CHIGH(n)

Specifies color for bars that have the n highest values

CLOW(n)

Specifies color for bars that have the n lowest values

LABOTHER=

Specifies a label for the OTHER= category

LAST=

Specifies the bottommost category

Options for the Cumulative Percentage Curve

ANCHOR=

Specifies the corner of topmost bar to which the curve is anchored

CMPCTLABEL

Labels curve points with their values

NOCURVE

Suppresses the cumulative percentage curve

NOCUMLABEL

Suppresses the cumulative percentage axis label

NOCUMTICK

Suppresses the cumulative percentage axis tick marks and tick mark labels

Options for Comparative Pareto Charts

CLASS=

Specifies classification variables

CLASSKEY=

Specifies the key cell

CPROP

Requests proportion-of-frequency bars

INTERTILE=

Specifies the distance in screen percentage units between tiles

MISSING1

Requests that missing values of the first CLASS= variable be analyzed as a level

MISSING2

Requests that missing values of the second CLASS= variable be analyzed as a level

NCOLS=

Specifies the number of columns

NOKEYMOVE

Suppresses the placement of the key cell in the top left corner

NROWS=

Specifies the number of rows

ORDER1=

Specifies the order in which values of the first CLASS= variable are displayed

ORDER2=

Specifies the order in which values of the second CLASS= variable are displayed

Options for Controlling Axes

AXISFACTOR=

Specifies the distance factor between the longest bar and the right frame

FREQAXIS=

Specifies tick mark values for the frequency axis

FREQAXISLABEL=

Labels the frequency axis

CUMAXIS=

Specifies tick mark values for the cumulative percentage axis

CUMAXISLABEL=

Specifies a label for the cumulative percentage axis

FREQOFFSET=

Specifies the frequency axis offset in screen percentage units

GRID

Adds a grid that corresponds to the frequency axis

GRID2

Adds a grid that corresponds to the cumulative percentage axis

NOCHART

Suppresses the Pareto chart

NOFREQLABEL

Suppresses the frequency axis label

NOCUMLABEL

Suppresses the cumulative percentage axis label

NOFREQTICK

Suppresses tick marks and tick mark labels for the frequency axis

NOCUMTICK

Suppresses tick marks and tick mark labels for the cumulative percentage axis

NOCATLABEL

Suppresses the category axis label

SCALE=

Specifies the units in which the frequency axis is scaled

CATOFFSET=

Specifies the category axis offset in screen percentage units

Options for Reference Lines

CATREF=

Requests reference lines perpendicular to the category axis

CATREFLABELS=

Specifies labels for CATREF= lines

CUMREF=

Requests reference lines perpendicular to the cumulative percentage axis

CUMREFLABELS=

Specifies labels for CUMREF= lines

FREQREF=

Requests reference lines perpendicular to the frequency axis

FREQREFLABELS=

Specifies labels for FREQREF= lines

HREFLABPOS=

Specifies the position of FREQREFLABELS= and CUMREFLABELS= labels

VREFLABPOS=

Specifies the position of CATREFLABELS= labels

Options for Displaying Legends

BARLEGEND=

Displays a legend for the BARS=, CBARS=, or PBARS= options

BARLEGLABEL=

Displays a label for the BARLEGEND= legend

CATLEGLABEL=

Specifies a label for the Pareto categories legend

CFRAMENLEG

Frames the sample size legend

HLLEGLABEL=

Displays a label for the legend that describes colors and patterns of the highest or lowest bars

NLEGEND=

Requests a sample size legend

NOHLLEG

Suppresses the legend that describes colors and patterns of the highest and lowest bars

Options for ODS Graphics Output

CATLEGEND=

Controls the display of the Pareto categories legend

CHARTTYPE=

Specifies the type of Pareto chart to be produced

MARKERS

Requests markers on the cumulative percentage curve

ODSFOOTNOTE=

Specifies a footnote to be displayed on the chart

ODSFOOTNOTE2=

Specifies a secondary footnote to be displayed on the chart

ODSTITLE=

Specifies a title to be displayed on the chart

ODSTITLE2=

Specifies a secondary title to be displayed on the chart

URL=

Specifies a variable whose values are URLs to be associated with bars

Options for Traditional Graphics

ANGLE=

Rotates category axis tick mark labels

ANNOKEY

Applies annotation only to the key cell

ANNOTATE=

Specifies an annotation data set that uses frequency axis data units

ANNOTATE2=

Specifies an annotation data set that uses cumulative percentage axis data units

BARLABPOS=

Specifies the position of BARLABEL= labels

BARWIDTH=

Specifies the width (vertical dimension) of the bars in screen percentage units

CAXIS=

Specifies the axis color

CAXIS2=

Specifies the color for the cumulative percentage axis and tick marks

CBARLINE=

Specifies the color for bar outlines

CBARS=

Specifies the color for bars

CCATREF=

Specifies the color for CATREF= lines

CCONNECT=

Specifies the color for the curve

CCUMREF=

Specifies the color for CUMREF= lines

CFRAME=

Specifies the color for the area enclosed by axes and frame

CFRAMESIDE=

Specifies the frame color for row labels

CFRAMETOP=

Specifies the frame color for column labels

CFREQREF=

Specifies the color for FREQREF= lines

CGRID=

Specifies the color for frequency axis grid lines

CGRID2=

Specifies the color for cumulative percentage axis grid lines

CLIPREF

Draws reference lines behind bars

COTHER=

Specifies the color for OTHER= bar

CTEXT=

Specifies the color for text

CTEXTSIDE=

Specifies the color for row labels

CTEXTTOP=

Specifies the color for column labels

CTILES=

Specifies the colors for tile backgrounds

DESCRIPTION=

Specifies a description of the Pareto chart’s GRSEG catalog entry

FONT=

Specifies the font for text

FRONTREF

Draws reference lines in front of bars

HEIGHT=

Specifies the text height in screen percentage units

HTML=

Specifies a variable whose values create links that are associated with bars in traditional graphics output

INFONT=

Specifies the font for text inside the frame

INHEIGHT=

Specifies the text height in screen percentage units for text inside the frame

INTERBAR=

Specifies the distance between bars in screen percentage units

LCATREF=

Specifies the line type for CATREF= lines

LCUMREF=

Specifies the line type for CUMREF= lines

LFREQREF=

Specifies the line type for FREQREF= lines

LGRID=

Specifies the line type for frequency axis grid lines

LGRID2=

Specifies the line type for cumulative percentage axis grid lines

NAME=

Specifies the name of the Pareto chart’s GRSEG catalog entry

NOFRAME

Suppresses the axis frame

PBARS=

Specifies the pattern for the bars

PHIGH(n)=

Specifies the pattern for bars that have the n highest values

PLOW(n)=

Specifies the pattern for bars that have the n lowest values

POTHER=

Specifies the pattern for the OTHER= bar

TILELEGEND=

Specifies a legend for the CTILES= colors

TILELEGLABEL=

Specifies label for TILELEGEND= legend

WAXIS=

Specifies the width in pixels for the axes and frame

WBARLINE=

Specifies the width for bar outlines

WGRID=

Specifies the width of frequency axis grid lines

WGRID2=

Specifies the width of cumulative percentage axis grid lines