Examples (DETECTANOMALY command)
DETECTANOMALY
/VARIABLES CATEGORICAL=A B C SCALE=D E
/SAVE ANOMALY REASON.
-
DETECTANOMALY
treats variables A, B, and C as categorical variables and D and E as continuous variables. - All of the processed variables are then used in the
analysis to generate the anomaly list. Since no
ID
option is specified, the case number is used as the case identity variable. The size of the list is the number of cases with an anomaly index of at least 2.0 and is not more than 5% of the size of the working file. The anomaly list consists of theID
variable, the anomaly index, the peer group ID and size, and the reason. By default, there is one reason for each anomaly. Each reason consists of information such as the variable impact measure, the variable name for this reason, the value of the variable, and the value of the corresponding peer group. The anomaly list is presented in the pivot table output. - Since the keywords
ANOMALY
andREASON
are specified in theSAVE
subcommand, the additional variables for the anomaly index and the anomaly reason are added to the active dataset.
Specifying a Case ID Variable and Excepted Variables
DETECTANOMALY
/VARIABLES ID=CaseID EXCEPT=GeoID DemoID AddressID.
-
DETECTANOMALY
uses all variables in the active dataset in the analysis, except the variables GeoID, DemoID, and AddressID, which are excluded. Moreover, it treats the variable CaseID as theID
variable in the procedure. The processed variables are used in the analysis to generate the anomaly list.