KMeans Function Syntax | Teradata Vantage - KMeans Syntax - Teradata Vantage

Machine Learning Engine Analytic Function Reference

Product
Teradata Vantage
Release Number
9.02
9.01
2.0
1.3
Published
February 2022
Language
English (United States)
Last Update
2022-02-10
dita:mapPath
rnn1580259159235.ditamap
dita:ditavalPath
ybt1582220416951.ditaval
dita:id
B700-4003
lifecycle
previous
Product Category
Teradata Vantageā„¢

Version 1.20

SELECT * FROM KMeans (
  ON { table | view | (query) } AS InputTable
  [ ON { table | view | (query) } AS CentroidsTable ]
  OUT TABLE OutputTable (output_table)
  [ OUT TABLE ClusterAssignmentTable (cluster_assignement_table) ]
  USING
  [ IDColumn ('id_column') ]
  [ TargetColumns ({ 'target_column' | target_column_range [,...]) ]
  [ UnpackColumns ({'true'|'t'|'yes'|'y'|'1'|'false'|'f'|'no'|'n'|'0'}) ]
  [ InitialSeeds ('starting_cluster' [,...]) ]
  [ NumClusters (number_of_means) [ Seed (seed) ] ]
  [ StopThreshold (threshold) ]
  [ MaxIterNum (max_iterations) ]
) AS alias;

You must specify only one of NumClusters, InitialSeeds, or CentroidsTable. If you specify more than one, the function gives top priority to InitialSeeds, then to NumClusters, and then to CentroidsTable.