|
Chapter Contents |
Previous |
Next |
| The REG Procedure |
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.
For detailed examples of painting scatter plots, see the section "Painting Scatter Plots".
Condition is used to select observations to be painted. The syntax of condition is
variable compare valueor
variable compare value logical variable compare valuewhere
paint name='henry';and
paint name='Henry';are not the same.
Examples of the variable compare value form are
paint name='Henry'; paint residual.>=20; paint obs.=99;Examples of the variable compare value logical variable compare value form are
paint name='Henry'|name='Mary'; paint residual.>=20 or residual.<=10; paint obs.>=11 and residual.<=20;
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 when 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 (/).
paint / symbol='#';changes the painting symbol for the observations selected by the most recent PAINT statement to '#'. As another example,
paint temp lt 22 / symbol='c';changes the painting symbol to 'c' for all observations with TEMP<22. In general, the numbers 1, 2, ... , 9 and the asterisk are not recommended as painting symbols. These symbols are used as default symbols in the PLOT statement, where they represent the number of replicates at a point. If SYMBOL='' is used, no painting is done in the current plot. If SYMBOL=' ' is used, observations are painted with a blank and are no longer seen on the plot.
Instead of specifying condition or the ALLOBS option, you can use the STATUS or UNDO option as follows:
paint obs. <=10 / symbol='a'; ...other interactive statements paint obs.=1 / symbol='b'; ...other interactive statements paint undo;The last PAINT statement changes the plotting symbol used for observation 1 back to 'a'. If the statement
paint / reset;is used instead, observation 1 is unpainted.
|
Chapter Contents |
Previous |
Next |
Top |
Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.