1.1 - 8.10 - SVMDensePredict Example: Linear Model - Teradata Vantage

Teradata Vantage™ - Machine Learning Engine Analytic Function Reference

Product
Teradata Vantage
Release Number
1.1
8.10
Release Date
October 2019
Content Type
Programming Reference
Publication ID
B700-4003-079K
Language
English (United States)

Input

SQL Call

SELECT * FROM SVMDensePredict (
  ON svm_iris_test AS InputTable PARTITION BY ANY
  ON densesvm_iris_linear_model AS Model dimension
  USING
  IdColumn ('id')
  TargetColumns ('[1:4]')
  Accumulate ('id','species')
  TopK (2)
) AS dt ORDER BY id, predict_confidence DESC;

Output

 id  predict_value predict_confidence   species    
 --- ------------- -------------------- ---------- 
   5 setosa          0.9748932667125186 setosa    
   5 versicolor     0.02510368739037196 setosa    
  10 setosa          0.8981285759448707 setosa    
  10 versicolor     0.10186168082935153 setosa    
  15 setosa          0.9897981989003938 setosa    
  15 versicolor    0.010201666975511153 setosa    
  20 setosa          0.9832039148915164 setosa    
  20 versicolor    0.016792917385510354 setosa    
  25 setosa          0.9130953221049072 setosa    
  25 versicolor     0.08687161792082065 setosa    
  30 setosa          0.9241821718150943 setosa    
  30 versicolor     0.07579413413525969 setosa    
  35 setosa          0.9136924815849163 setosa    
  35 versicolor     0.08629369375181632 setosa    
  40 setosa          0.9506685541218484 setosa    
  40 versicolor     0.04932636999249368 setosa    
  45 setosa          0.9706987357202538 setosa    
  45 versicolor    0.029285350353822046 setosa    
  50 setosa           0.950879713556542 setosa    
  50 versicolor     0.04911471733387025 setosa    
  55 versicolor      0.8230677408729492 versicolor
  55 virginica       0.1134018961939518 versicolor
  60 versicolor      0.4512401419485612 versicolor
  60 virginica       0.3875657925327765 versicolor
  65 versicolor      0.5514157068277608 versicolor
  65 setosa          0.3776099961199302 versicolor
  70 versicolor      0.8548733933631867 versicolor
  70 setosa         0.09130042869274542 versicolor
  75 versicolor      0.8563673401908461 versicolor
  75 setosa         0.10666172978775906 versicolor
  80 versicolor      0.8038846041246797 versicolor
  80 setosa         0.18219160234791884 versicolor
  85 virginica       0.6245936743376878 versicolor
  85 versicolor      0.2996647700226596 versicolor
  90 versicolor      0.7168244759603916 versicolor
  90 virginica      0.18714382507431257 versicolor
  95 versicolor      0.7057694520961759 versicolor
  95 virginica      0.19586907088324168 versicolor
 100 versicolor      0.7173051801315895 versicolor
 100 setosa         0.14494076629181576 versicolor
 105 virginica       0.9628477786966746 virginica 
 105 versicolor     0.03550737818857624 virginica 
 110 virginica       0.9701250552768823 virginica 
 110 versicolor     0.02642113961299587 virginica 
 115 virginica        0.992788804337352 virginica 
 115 versicolor    0.005910913672188769 virginica 
 120 versicolor      0.5704940757132779 virginica 
 120 virginica       0.4229285806824686 virginica 
 125 virginica         0.89329422678779 virginica 
 125 versicolor      0.0983699557323829 virginica 
 130 versicolor      0.8217890426060318 virginica 
 130 virginica      0.16917471047485888 virginica 
 135 versicolor      0.5393376024463379 virginica 
 135 virginica       0.4566232703520392 virginica 
 140 virginica       0.7617672081597969 virginica 
 140 versicolor     0.21957392324299813 virginica 
 145 virginica       0.9838068030027856 virginica 
 145 versicolor    0.013767131865085287 virginica 
 150 virginica       0.8473336317497223 virginica 
 150 versicolor     0.13739611470121008 virginica

Download a zip file of all examples and a SQL script file that creates their input tables from the attachment in the left sidebar.