RANGEATTRVAR Statement

RANGEATTRVAR Statement Syntax

Creates a named association between a range attribute map of numeric values or value ranges and an input data column.
RANGEATTRVAR ATTRVAR=attrvar-name
VAR=data-column | expression | dynamic
ATTRMAP="attrmap-name";
For a specific example, see the Example Program.

RANGEATTRVAR Statement Summary

The RANGEATTRVAR statement creates and names an association between colors that are specified in a RANGEATTRMAP block and a numeric column that is in the data. Attribute maps can be useful for controlling the application of gradient color in a graph or specifying data values that are independent of the actual data. The name that is assigned to the association in the RANGEATTRVAR statement is the name that plot statements must reference to use the attribute map.
Defining and using a numeric-range attribute map requires you to coordinate settings on several statements. For more information, see the RANGEATTRMAP statement’s Statement Summary.
The RANGEATTRVAR statement must be located within the BEGINGRAPH block but outside of the outermost layout block. It cannot be nested in a RANGEATTRMAP statement.

RANGEATTRVAR Statement Required Arguments

ATTRVAR= attrvar-name
specifies a SAS name for the map. This name must be unique among the RANGEATTRVAR statements within the template. The assigned name can be referenced by other statements that can be associated with the range attribute map.the attrvar-name
VAR= data-column | expression | dynamic
specifies a numeric input data column to be associated with an attribute map at run time. If an expression is used, a new column of transformed values is created and then matched with the attribute map.
Interaction. If the column is not found or the column is of the wrong type for the attribute map, the RANGEATTRVAR statement is ignored.
ATTRMAP="attrmap-name "
specifies the name of an existing range attribute map.
Restriction: The attrmap-name is case sensitive, must be enclosed in quotation marks, and must be the name that was assigned to the attribute map in the RANGEATTRMAP statement’s NAME= argument.