PAINT
<condition |ALLOBS> </ options> ;
PAINT
<STATUS |UNDO> ;
The PAINT statement is used with line printer plots. See the PLOTS= option for information about using ODS graphics to create modern statistical graphics.
The PAINT statement selects observations to be painted or highlighted in a scatter plot on line printer output; the PAINT statement is ignored if the LINEPRINTER option is not specified in the PROC REG statement.
All observations that satisfy condition are painted using some specific symbol. The PAINT statement does not generate a scatter plot and must be followed by a PLOT statement, which does generate a scatter plot. Several PAINT statements can be used before a PLOT statement, and all prior PAINT statement requests are applied to all later PLOT statements.
The PAINT statement lists the observation numbers of the observations selected, the total number of observations selected, and the plotting symbol used to paint the points.
On a plot, paint symbols take precedence over all other symbols. If any position contains more than one painted point, the paint symbol for the observation plotted last is used.
The PAINT statement cannot be used when a TYPE=CORR, TYPE=COV, or TYPE=SSCP data set is used as the input data set for PROC REG. Also, the PAINT statement cannot be used for models with more than one dependent variable. Note that the syntax for the PAINT statement is the same as the syntax for the REWEIGHT statement.
Condition is used to select observations to be painted. The syntax of condition is
variable compare value
or
variable compare value logical variable compare value
where
is one of the following:
a variable name in the input data set
OBS., which is the observation number
keyword., where keyword is a keyword for a statistic requested in the OUTPUT statement
is an operator that compares variable to value. Compare can be any one of the following: <, <=, >, >=, =, ^=. The operators LT, LE, GT, GE, EQ, and NE, respectively, can be used instead of the preceding symbols. See the “Expressions” section in SAS Language Reference: Concepts for more information about comparison operators.
gives an unformatted value of variable. Observations are selected to be painted if they satisfy the condition created by variable compare value. Value can be a number or a character string. If value is a character string, it must be eight characters or less and must be enclosed in quotes. In addition, value is case-sensitive. In other words, the statements
paint name='henry';
and
paint name='Henry';
are not the same.
is one of two logical operators. Either AND or OR can be used. To specify AND, use AND or the symbol &. To specify OR, use OR or the symbol |.
Here are some examples of the variable compare value form:
paint name='Henry'; paint residual.>=20; paint obs.=99;
Here are some examples of the variable compare value logical variable compare value form:
paint name='Henry'|name='Mary'; paint residual.>=20 or residual.<=10; paint obs.>=11 and residual.<=20;
Instead of specifying condition, the ALLOBS option can be used to select all observations. This is most useful when you want to unpaint all observations. For example,
paint allobs / reset;
resets the symbols for all observations.
The following options can be used when either a condition is specified, the ALLOBS option is specified, or nothing is specified before the slash. If only an option is listed, the option applies to the observations selected in the previous PAINT statement, not to the observations selected by reapplying the condition from the previous PAINT statement. For example, in the statements
paint r.>0 / symbol='a'; reweight r.>0; refit; paint / symbol='b';
the second PAINT statement paints only those observations selected in the first PAINT statement. No additional observations are painted even if, after refitting the model, there are new observations that meet the condition in the first PAINT statement.
Note: Options are not available when either the UNDO or STATUS option is used.
You can specify the following options after a slash (/).
Instead of specifying condition or the ALLOBS option, you can use the STATUS or UNDO option as follows: