1.1 - 8.10 - LARPredict Example: Model ('diabetes_lasso') - 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 LARPredict (
  ON diabetes_test AS InputTable PARTITION BY ANY
  ON diabetes_lasso AS Model DIMENSION
  USING
  CoefMode ('step')
  CoefPositions (1.6)
  ResponseColumn ('y')
) AS dt ORDER BY id;

Output

 id   age                  sex                bmi                  map1                 tc                   ldl                  hdl                  tch                  ltg                  glu                  y     prediction_1.6     
 ---- -------------------- ------------------ -------------------- -------------------- -------------------- -------------------- -------------------- -------------------- -------------------- -------------------- ----- ------------------ 
 NULL                 NULL               NULL                 NULL                 NULL                 NULL                 NULL                 NULL                 NULL                 NULL                 NULL  NULL         230114.375
 NULL                 NULL               NULL                 NULL                 NULL                 NULL                 NULL                 NULL                 NULL                 NULL                 NULL  NULL       272756.59375
    3   0.0852989062966783 0.0506801187398187   0.0444512133365941 -0.00567061055493425  -0.0455994512826475  -0.0341944659141195  -0.0323559322397657 -0.00259226199818282  0.00286377051894013  -0.0259303389894746 141.0 153.73690795898438
    6  -0.0926954778032799 -0.044641636506989  -0.0406959404999971  -0.0194420933298793  -0.0689906498720667  -0.0792878444118122   0.0412768238419757   -0.076394503750001  -0.0411803851880079  -0.0963461565416647  97.0 150.66551208496094
    8   0.0635036755905609 0.0506801187398187 -0.00189470584028465   0.0666296740135272   0.0906198816792644    0.108914381123697   0.0228686348215404   0.0177033544835672  -0.0358167281015492  0.00306440941436832  63.0  152.0651397705078
   13   0.0162806757273067 -0.044641636506989  -0.0288400076873072 -0.00911348124867051 -0.00432086553661359 -0.00976888589453599   0.0449584616460628  -0.0394933828740919  -0.0307512098645563  -0.0424987666488135 179.0  151.0931854248047
   14  0.00538306037424807 0.0506801187398187 -0.00189470584028465   0.0081008722200108 -0.00432086553661359  -0.0157187066685371  -0.0029028298070691 -0.00259226199818282   0.0383932482116977  -0.0135040182449705 185.0  152.0651397705078
   17 -0.00551455497881059 -0.044641636506989   0.0422955891888323   0.0494153205448459   0.0245741444856101  -0.0238605666750649   0.0744115640787594  -0.0394933828740919   0.0522799997967812   0.0279170509033766 166.0 153.65914916992188
   26   -0.067267708646143 0.0506801187398187  -0.0126728265790937  -0.0400993174922969  -0.0153284884022226   0.0046359433477825  -0.0581273968683752   0.0343088588777263   0.0191990330785671  -0.0342145528191441 202.0 151.67636108398438
   28  -0.0236772472339084 -0.044641636506989   0.0595405823709267  -0.0400993174922969  -0.0428475455662452  -0.0435889197678055   0.0118237214092792  -0.0394933828740919  -0.0159982677581387   0.0403433716478807  85.0  154.2812042236328
   30   0.0671362140415805 0.0506801187398187 -0.00620595413580824    0.063186803319791  -0.0428475455662452  -0.0958847128866574    0.052321737254237   -0.076394503750001   0.0594238004447941   0.0527696923923848 283.0  151.9096221923828
   33   0.0344433679824045 0.0506801187398187    0.125287118877662   0.0287580963824284  -0.0538551684318543  -0.0129003705124313    -0.10230705051742    0.108111100629544  2.71485727907132E-4   0.0279170509033766 341.0  156.6527862548828
   35   0.0162806757273067 -0.044641636506989   -0.063329994051496  -0.0573136709609782  -0.0579830270064577  -0.0489124436182275  0.00814208360519211  -0.0394933828740919  -0.0594726974107223  -0.0673514081378217  65.0  149.8490753173828
   48  -0.0781653239992017 -0.044641636506989  -0.0730303027164241  -0.0573136709609782  -0.0841261313122791  -0.0742774690231797  -0.0249926566315915  -0.0394933828740919  -0.0181182673078967  -0.0839198357971606 142.0 149.49916076660156
   50  -0.0418399394890061 0.0506801187398187   0.0142724752679289 -0.00567061055493425  -0.0125765826858204  0.00620168565673016  -0.0728539480847234   0.0712099797536354   0.0354619386607697  -0.0135040182449705 142.0  152.6483154296875
   64   -0.034574862586967 -0.044641636506989  -0.0374625042783544  -0.0607565416547144   0.0204462859110067   0.0434663526096845  -0.0139477432193303 -0.00259226199818282  -0.0307512098645563  -0.0714935150526564 128.0  150.7821502685547
   66  -0.0454724779400257 0.0506801187398187  -0.0245287593917836   0.0597439326260547  0.00531080447079431   0.0149698425868371  -0.0544457590642881   0.0712099797536354   0.0423448954496075   0.0154907301588724 163.0 151.24868774414062
   68   0.0417084448844436 0.0506801187398187  -0.0148284507268555  -0.0171468461892456 -0.00569681839481472  0.00839372488925688  -0.0139477432193303 -0.00185423958066465  -0.0119006848015081  0.00306440941436832  97.0 151.59860229492188
   78  -0.0963280162542995 -0.044641636506989  -0.0363846922044735  -0.0745280244296595  -0.0387196869916418  -0.0276183482165393   0.0155053592133662  -0.0394933828740919  -0.0740888714915354 -0.00107769750046639 200.0 150.82102966308594
   79  0.00538306037424807 -0.044641636506989  -0.0579409336820915  -0.0228849640236156  -0.0676146970138656  -0.0683276482491785  -0.0544457590642881 -0.00259226199818282   0.0428956878925287  -0.0839198357971606 252.0    150.04345703125
   84  -0.0382074010379866 -0.044641636506989  0.00996122697240527  -0.0469850588797694  -0.0593589798646588  -0.0529833736214915  -0.0102661054152432  -0.0394933828740919  -0.0159982677581387  -0.0424987666488135 210.0  152.4927978515625
   98  -0.0273097856849279 -0.044641636506989   0.0886415083657111  -0.0251802111642493   0.0218222387692079   0.0425269072243159  -0.0323559322397657   0.0343088588777263  0.00286377051894013   0.0776223338813931 279.0 155.33091735839844
   99  0.00175052192322852 0.0506801187398187 -0.00512814206192736  -0.0125563519424068  -0.0153284884022226  -0.0138398158977999  0.00814208360519211  -0.0394933828740919 -0.00608024819631442  -0.0673514081378217  92.0 151.94850158691406
  100 -0.00188201652779104 -0.044641636506989  -0.0644078061253769   0.0115437429137471   0.0273260502020124   0.0375165318356834  -0.0139477432193303   0.0343088588777263   0.0117839003835759  -0.0549250873933176  83.0 149.81019592285156
  105  -0.0273097856849279 -0.044641636506989   0.0649296427403312 -0.00222773986119799  -0.0249601584096305  -0.0172844489774848   0.0228686348215404  -0.0394933828740919  -0.0611765950943345   -0.063209301222987  95.0 154.47560119628906
  107  -0.0963280162542995 -0.044641636506989  -0.0762637389380668  -0.0435421881860331  -0.0455994512826475  -0.0348207628376986  0.00814208360519211  -0.0394933828740919  -0.0594726974107223  -0.0839198357971606 134.0 149.38253784179688
  116  -0.0309423241359475 0.0506801187398187  0.00133873038135806 -0.00567061055493425   0.0644767773734429   0.0494161733836856  -0.0470824834561139    0.108111100629544   0.0837967663655224  0.00306440941436832 229.0 152.18177795410156
  135  -0.0745327855481821 -0.044641636506989   0.0433734012627132  -0.0332135761048244      0.0121905687618  2.51864882729031E-4   0.0633666506664982  -0.0394933828740919  -0.0271286455543265  -0.0466408735636482 103.0 153.69802856445312
  136 -0.00551455497881059 -0.044641636506989    0.056307146149284  -0.0366564467985606  -0.0483513569990498  -0.0429626228442264  -0.0728539480847234   0.0379989709653172   0.0507815133629732   0.0569117993072195 272.0 154.16456604003906
  152  0.00175052192322852 -0.044641636506989 -0.00405032998804645 -0.00567061055493425 -0.00844872411121698  -0.0238605666750649    0.052321737254237  -0.0394933828740919  -0.0089440189577978  -0.0135040182449705  88.0  151.9873809814453
  156  -0.0273097856849279 0.0506801187398187   0.0606183944448076   0.0494153205448459   0.0851160702464598   0.0863676918748504  -0.0029028298070691   0.0343088588777263   0.0378144788263439   0.0486275854775501 186.0 154.32008361816406
  159  -0.0127796318808497 -0.044641636506989  -0.0654856181992578  -0.0699375301828207  0.00118294589619092   0.0168487333575743  -0.0029028298070691 -0.00702039650329191  -0.0307512098645563  -0.0507829804784829  96.0  149.7713165283203
  162  -0.0454724779400257 0.0506801187398187   0.0638518306664503   0.0700725447072635    0.133274420283499    0.131461070372543  -0.0397192078479398    0.108111100629544   0.0757375884575476   0.0859065477110625 217.0  154.4367218017578
  163  -0.0527375548420648 -0.044641636506989   0.0304396563761424  -0.0745280244296595  -0.0235842055514294  -0.0113346282034837  -0.0029028298070691 -0.00259226199818282  -0.0307512098645563 -0.00107769750046639 172.0  153.2314910888672
  166  -0.0418399394890061 -0.044641636506989  -0.0665634302731387  -0.0469850588797694  -0.0373437341334407   -0.043275771306016   0.0486400994501499  -0.0394933828740919  -0.0561575730950062  -0.0135040182449705  59.0 149.73243713378906
  167  -0.0563700932930843 0.0506801187398187  -0.0600965578298533  -0.0366564467985606  -0.0882539898868825  -0.0708328359434948  -0.0139477432193303  -0.0394933828740919  -0.0781409106690696   -0.104630370371334  70.0 149.96571350097656
  171   0.0235457526293458 0.0506801187398187    -0.02021751109626  -0.0366564467985606  -0.0139525355440215   -0.015092409744958   0.0596850128624111  -0.0394933828740919  -0.0964332228917841  -0.0176461251598052  47.0 151.40420532226562
  174  -0.0636351701951234 0.0506801187398187  -0.0794971751597095 -0.00567061055493425   -0.071742555588469  -0.0664487574784414  -0.0102661054152432  -0.0394933828740919  -0.0181182673078967  -0.0549250873933176 101.0 149.26589965820312
  179   0.0417084448844436 -0.044641636506989 -0.00836157828357004  -0.0263278347173518   0.0245741444856101   0.0162224364339952   0.0707299262746723  -0.0394933828740919  -0.0483617248028919  -0.0300724459043093  81.0  151.8318634033203
  180  -0.0236772472339084 -0.044641636506989  -0.0159062628007364  -0.0125563519424068   0.0204462859110067   0.0412743133771578  -0.0434008456520269   0.0343088588777263   0.0140724525157685  -0.0093619113301358 151.0 151.55972290039062
  188   -0.067267708646143 -0.044641636506989  -0.0547074974604488  -0.0263278347173518  -0.0758704141630723   -0.082106180567918   0.0486400994501499   -0.076394503750001  -0.0868289932162924   -0.104630370371334 143.0 150.16009521484375
  190 -0.00188201652779104 -0.044641636506989  -0.0665634302731387  0.00121513083253827 -0.00294491267841247  0.00307020103883484   0.0118237214092792 -0.00259226199818282  -0.0202887477516296  -0.0259303389894746  79.0 149.73243713378906
  192 -0.00551455497881059 0.0506801187398187   -0.041773752573878  -0.0435421881860331  -0.0799982727376757  -0.0761563597939169  -0.0323559322397657  -0.0394933828740919   0.0102256424049578  -0.0093619113301358 178.0  150.6266326904297
  197  -0.0236772472339084 -0.044641636506989  -0.0460850008694016  -0.0332135761048244   0.0328298616348169   0.0362639379885253   0.0375951860378887 -0.00259226199818282  -0.0332487872476258   0.0113486232440377  72.0 150.47113037109375
  199  -0.0527375548420648 -0.044641636506989   0.0541515220015222  -0.0263278347173518  -0.0552311212900554    -0.03388131745233  -0.0139477432193303  -0.0394933828740919  -0.0740888714915354  -0.0590671943081523 142.0 154.08680725097656
  202   -0.034574862586967 0.0506801187398187  -0.0557853095343297   -0.015999222636143 -0.00982467696941811 -0.00788999512379879   0.0375951860378887  -0.0394933828740919  -0.0529587932392004   0.0279170509033766  39.0  150.1212158203125
  205    0.110726675453815 0.0506801187398187  0.00672779075076256   0.0287580963824284  -0.0277120641260328 -0.00726369820021974  -0.0470824834561139   0.0343088588777263  0.00200784054982379   0.0776223338813931 277.0 152.37615966796875
  218   0.0744012909436196 -0.044641636506989   0.0315174684500233     0.10105838095089   0.0465893902168282   0.0368902349121043   0.0155053592133662 -0.00259226199818282   0.0336568129023847   0.0444854785627154 296.0 153.27037048339844
  222  -0.0454724779400257 -0.044641636506989  -0.0385403163522353  -0.0263278347173518  -0.0153284884022226  8.78161806308105E-4  -0.0323559322397657 -0.00259226199818282  0.00114379737951254  -0.0383566597339788  93.0 150.74327087402344
  232  0.00901559882526763 -0.044641636506989   -0.030995631835069   0.0218723549949558  0.00806271018719657  0.00870687335104641  0.00446044580110504 -0.00259226199818282  0.00943640914607987   0.0113486232440377 154.0  151.0154266357422
  246  -0.0273097856849279 -0.044641636506989  -0.0353068801305926  -0.0297707054110881  -0.0566070741482565   -0.058620045933703   0.0302319104297145  -0.0394933828740919  -0.0498684677352306   -0.129483011860342 125.0  150.8599090576172
  250  -0.0127796318808497 -0.044641636506989   0.0606183944448076   0.0528581912385822   0.0479653430750293   0.0293746718291555  -0.0176293810234174   0.0343088588777263   0.0702112981933102  0.00720651632920303 215.0 154.32008361816406
  256  0.00175052192322852 -0.044641636506989  -0.0654856181992578 -0.00567061055493425 -0.00707277125301585  -0.0194764882100115   0.0412768238419757  -0.0394933828740919   -0.003303712578677  0.00720651632920303 153.0  149.7713165283203
  257  -0.0491050163910452 -0.044641636506989    0.160854917315731  -0.0469850588797694  -0.0290880169842339   -0.019789636671801  -0.0470824834561139   0.0343088588777263    0.028016506523264   0.0113486232440377 346.0 157.93577575683594
  258  -0.0273097856849279 0.0506801187398187  -0.0557853095343297   0.0253152256886921 -0.00707277125301585  -0.0235474182132754    0.052321737254237  -0.0394933828740919 -0.00514530798026311  -0.0507829804784829  63.0  150.1212158203125
  277   0.0126481372762872 -0.044641636506989   0.0261284080806188    0.063186803319791    0.125018703134293   0.0916912157252725   0.0633666506664982 -0.00259226199818282   0.0575728562024259  -0.0217882320746399 283.0  153.0759735107422
  282  -0.0926954778032799 0.0506801187398187  -0.0902752958985185  -0.0573136709609782  -0.0249601584096305  -0.0304366843726451 -0.00658446761115617 -0.00259226199818282    0.024052583226893  0.00306440941436832  94.0 148.87710571289062
  286   0.0126481372762872 -0.044641636506989    -0.02021751109626   -0.015999222636143      0.0121905687618   0.0212328118226277  -0.0765355858888105    0.108111100629544   0.0598807230654812  -0.0217882320746399 233.0 151.40420532226562
  289      0.0707687524926 0.0506801187398187  -0.0169840748746173   0.0218723549949558   0.0438374845004259   0.0563054395430553   0.0375951860378887 -0.00259226199818282  -0.0702093127286876  -0.0176461251598052  80.0 151.52084350585938
  293  0.00901559882526763 -0.044641636506989  -0.0223731352440218  -0.0320659525517218  -0.0497273098572509  -0.0686407967109681   0.0780932018828464  -0.0708593356186146  -0.0629129499162512  -0.0383566597339788  84.0 151.32644653320312
  296  -0.0527375548420648 0.0506801187398187   0.0390621529671896  -0.0400993174922969 -0.00569681839481472  -0.0129003705124313   0.0118237214092792  -0.0394933828740919   0.0163049527999418  0.00306440941436832  85.0 153.54251098632812
  301   0.0162806757273067 -0.044641636506989   0.0735521393313785  -0.0412469410453994 -0.00432086553661359  -0.0135266674360104  -0.0139477432193303 -0.00111621716314646   0.0428956878925287   0.0444854785627154 275.0    154.78662109375
  307  0.00901559882526763 0.0506801187398187 -0.00189470584028465   0.0218723549949558  -0.0387196869916418  -0.0248000120604336 -0.00658446761115617  -0.0394933828740919  -0.0398095943643375  -0.0135040182449705  44.0  152.0651397705078
  308   0.0671362140415805 0.0506801187398187   -0.030995631835069  0.00465800152627453   0.0245741444856101   0.0356376410649462  -0.0286742944356786   0.0343088588777263   0.0233748412798208   0.0817644407962278 172.0  151.0154266357422
  310 -0.00914709342983014 0.0506801187398187  0.00133873038135806 -0.00222773986119799   0.0796122588136553   0.0700839718617947   0.0339135482338016 -0.00259226199818282   0.0267142576335128   0.0817644407962278 142.0 152.18177795410156
  317   0.0162806757273067 0.0506801187398187   0.0142724752679289  0.00121513083253827  0.00118294589619092  -0.0213553789807487  -0.0323559322397657   0.0343088588777263   0.0749683360277342   0.0403433716478807 220.0  152.6483154296875
  320   0.0199132141783263 -0.044641636506989  0.00457216660300077   0.0459724498511097  -0.0180803941186249  -0.0545491159304391   0.0633666506664982  -0.0394933828740919   0.0286607203138089   0.0610539062220542 191.0  152.2984161376953
  323   0.0235457526293458 0.0506801187398187   0.0616962065186885   0.0620391798699746   0.0245741444856101  -0.0360733566848567  -0.0912621371051588    0.155344535350708    0.133395733837469   0.0817644407962278 242.0  154.3589630126953
  330  -0.0127796318808497 0.0506801187398187  -0.0557853095343297 -0.00222773986119799  -0.0277120641260328   -0.029184090525487   0.0191869970174533  -0.0394933828740919  -0.0170521046047435   0.0444854785627154 135.0  150.1212158203125
  333    0.030810829531385 -0.044641636506989    0.104808689473925    0.076958286094736  -0.0112006298276192  -0.0113346282034837  -0.0581273968683752   0.0343088588777263   0.0571041874478439    0.036201264733046 270.0 155.91409301757812
  334   0.0271782910803654 0.0506801187398187 -0.00620595413580824   0.0287580963824284  -0.0167044412604238 -0.00162702588800815  -0.0581273968683752   0.0343088588777263   0.0293004132685869   0.0320591578182113 164.0  151.9096221923828
  337  -0.0200447087828888 -0.044641636506989   0.0854080721440683  -0.0366564467985606   0.0919958345374655   0.0894991764927457  -0.0618090346724622    0.145012221505454   0.0809479135112756   0.0527696923923848 306.0  155.2142791748047
  338   0.0199132141783263 0.0506801187398187  -0.0126728265790937   0.0700725447072635  -0.0112006298276192  0.00714113104209875  -0.0397192078479398   0.0343088588777263  0.00538436996854573  0.00306440941436832  91.0 151.67636108398438
  340   0.0271782910803654 -0.044641636506989 -0.00728376620968916  -0.0504279295735057   0.0754844002390519   0.0566185880048449   0.0339135482338016 -0.00259226199818282   0.0434431722527813   0.0154907301588724  95.0 151.87074279785156
  345   -0.107225631607358 -0.044641636506989  -0.0115950145052127  -0.0400993174922969   0.0493412959332305   0.0644472995495832  -0.0139477432193303   0.0343088588777263  0.00702686254915195  -0.0300724459043093 200.0 151.71524047851562
  349    0.030810829531385 -0.044641636506989    -0.02021751109626 -0.00567061055493425 -0.00432086553661359  -0.0294972389872765   0.0780932018828464  -0.0394933828740919  -0.0109044358473771 -0.00107769750046639 148.0 151.40420532226562
  352  -0.0854304009012408 0.0506801187398187  -0.0406959404999971  -0.0332135761048244  -0.0813742255958769  -0.0695802420963367 -0.00658446761115617  -0.0394933828740919  -0.0578000656756125  -0.0424987666488135  71.0 150.66551208496094
  353   0.0126481372762872 0.0506801187398187  -0.0719524906425432  -0.0469850588797694   -0.051103262715452  -0.0971373067338155    0.118591217727804   -0.076394503750001  -0.0202887477516296  -0.0383566597339788  77.0  149.5380401611328
  362   0.0417084448844436 -0.044641636506989 -0.00728376620968916   0.0287580963824284  -0.0428475455662452  -0.0482861466946485    0.052321737254237   -0.076394503750001  -0.0721284546019561   0.0237749439885419 182.0 151.87074279785156
  372   0.0526060602375023 0.0506801187398187 -0.00943939035745095   0.0494153205448459   0.0507172487914316   -0.019163339748222  -0.0139477432193303   0.0343088588777263    0.119343994203787  -0.0176461251598052 197.0 151.79298400878906
  373  -0.0273097856849279 0.0506801187398187  -0.0234509473179027   -0.015999222636143   0.0135665216200011   0.0127778033543103   0.0265502726256275 -0.00259226199818282  -0.0109044358473771  -0.0217882320746399  71.0 151.28756713867188
  383   0.0489735217864827 -0.044641636506989   0.0606183944448076  -0.0228849640236156  -0.0235842055514294   -0.072711726714232  -0.0434008456520269 -0.00259226199818282    0.104137611358979    0.036201264733046 132.0 154.32008361816406
  394  -0.0745327855481821 -0.044641636506989  -0.0460850008694016  -0.0435421881860331  -0.0290880169842339  -0.0232342697514859   0.0155053592133662  -0.0394933828740919  -0.0398095943643375  -0.0217882320746399  69.0 150.47113037109375
  397  -0.0854304009012408 0.0506801187398187   -0.030995631835069  -0.0228849640236156  -0.0634868384392622  -0.0542359674686496   0.0191869970174533  -0.0394933828740919  -0.0964332228917841  -0.0342145528191441  43.0  151.0154266357422
  413   0.0744012909436196 -0.044641636506989   0.0854080721440683    0.063186803319791   0.0149424744782022   0.0130909518160999   0.0155053592133662 -0.00259226199818282  0.00620931561650541   0.0859065477110625 261.0  155.2142791748047
  431 -0.00914709342983014 -0.044641636506989  -0.0568631216082106  -0.0504279295735057   0.0218222387692079   0.0453452433804217  -0.0286742944356786   0.0343088588777263 -0.00991895736315477  -0.0176461251598052 183.0 150.08233642578125
  437  -0.0563700932930843 -0.044641636506989   -0.074108114790305  -0.0504279295735057  -0.0249601584096305  -0.0470335528474903   0.0928197530991947   -0.076394503750001  -0.0611765950943345  -0.0466408735636482  48.0  149.4602813720703
  438   0.0417084448844436 0.0506801187398187   0.0196615356373334   0.0597439326260547 -0.00569681839481472 -0.00256647127337676  -0.0286742944356786 -0.00259226199818282   0.0311929907028023  0.00720651632920303 178.0 152.84271240234375
  440   0.0417084448844436 0.0506801187398187  -0.0159062628007364   0.0172818607481171  -0.0373437341334407  -0.0138398158977999  -0.0249926566315915  -0.0110795197996419  -0.0468794828442166   0.0154907301588724 132.0 151.55972290039062
  442  -0.0454724779400257 -0.044641636506989  -0.0730303027164241   -0.081413765817132   0.0837401173882587   0.0278089295202079     0.17381578478911  -0.0394933828740919 -0.00421985970694603  0.00306440941436832  57.0 149.49916076660156

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