Skip to content

QUICK CLUSTER

K-means clustering: assigns each case to the nearest of k cluster centres, updating the centres until they stop moving.

QUICK CLUSTER varlist [/CRITERIA=CLUSTER(k) MXITER(10) CONVERGE(0) NOINITIAL] [/METHOD=KMEANS(NOUPDATE)|KMEANS(UPDATE)|CLASSIFY] [/INITIAL=(values)] [/PRINT=INITIAL ANOVA CLUSTER DISTAN SILHOUETTE ID(var) NONE] [/SAVE=CLUSTER DISTANCE] [/MISSING=LISTWISE|PAIRWISE|INCLUDE].
Kind Procedure (reads data, produces output)
Body main /SUBCOMMAND[=] …
Changes data yes, undoable
Subcommands /CRITERIA, /FILE, /INITIAL, /METHOD, /MISSING, /OUTFILE, /PRINT, /SAVE, /VARIABLES
Menu Analyze ▸ Classify
Slot: Variables 1+ variable(s); levels: scale; types: numeric
Slot: Label Cases by 0–1 variable(s); levels: nominal, ordinal, scale; types: numeric, string
  • CRITERIA: CLUSTER(k) number of clusters (2); MXITER(n) iterations (10); CONVERGE(c) stop when no centre moves more than c × the smallest distance between initial centres (0); NOINITIAL uses the first k cases as initial centres
  • METHOD: KMEANS(NOUPDATE) recomputes centres after each pass (default); KMEANS(UPDATE) after each case; CLASSIFY only assigns cases to the initial centres
  • INITIAL: k × p starting centres, cluster by cluster
  • SAVE: CLUSTER saves membership as QCL_n; DISTANCE saves the distance to the cluster centre
QUICK CLUSTER zincome zage zspend /CRITERIA=CLUSTER(4) MXITER(20) /PRINT=INITIAL ANOVA SILHOUETTE /SAVE=CLUSTER.
  • Distances are Euclidean, so variables on different scales should be standardized first (DESCRIPTIVES /SAVE).
  • The ANOVA F tests are descriptive only: the clusters were chosen to differ.

CLUSTER, TWOSTEP CLUSTER


Generated from OrcStat’s command registry and reference. To suggest a change, open an issue.