Syntax | Linear Regression Scoring | Vantage Analytics Library - Syntax - Vantage Analytics Library

Vantage Analytics Library User Guide

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
Lake
VMware
Product
Vantage Analytics Library
Release Number
2.2.0
Published
March 2023
Language
English (United States)
Last Update
2024-01-02
dita:mapPath
ibw1595473364329.ditamap
dita:ditavalPath
iup1603985291876.ditaval
dita:id
zyl1473786378775
Product Category
Teradata Vantage
CALL td_analyze (
  'linearscore',
  'required_parameter_list [ optional_parameter; [...] ]'
);
required_parameter_list
database = input_database_name;
tablename = input_table_name;
modeldatabase = model_database_name;
modeltablename = model_table_name;
optional_parameter
{ gensqlonly = { true | false } |
  outputdatabase = output_database_name |
  outputtablename = output_table_name |
  index = column_name [,...] |
  overwrite = { true | false } |
  predicted = column_name |
  residual = residual_column_name |
  retain = column_name [,...] |
  samplescoresize = sample_score_size |
  scoringmethod = { score | evaluate | scoreandevaluate }
}

Syntax Elements

database
The database containing the input table.
tablename
The input table to score.
modeldatabase
The database containing the model input table.
modeltablename
The input table containing the linear model to use in scoring, output by the Linear Regression function.
gensqlonly
[Optional] True returns the SQL for the function as a result set but does not run it.
False runs the SQL for the function but does not return it as a result set.
Default: false
outputdatabase
[Optional] The database that contains the output score table.
outputtablename
[Optional] The name of the score output table containing key columns and predicted values of the dependent variable in the linear model and any columns specified by groupby, residual, and retained.
If you do not specify both outputdatabase and outputtablename, the function returns a result set instead of any output table.
index
[Optional] The columns for the primary index of the score output table. These columns must form a unique key for the score output table. Otherwise, a given observation has more than one score.
These index columns are included both in the Primary Index clause and the select list.
Default: Primary index columns of the input table
overwrite
[Optional] Whether to drop the output tables before creating new ones.
Default: true
predicted
[Optional] The input table column that has the predicted value. Unnecessary if scoringmethod=evaluate.
Default: dependent
residual
[Optional] If scoringmethod=scoreandevaluate, the name of the input table column that has the residual value (the difference between the predicted and actual value of the dependent variable).
Default: Residual
retain
[Optional] One or more input table columns to be copy to the output table.
samplescoresize
[Optional] If scoringmethod=score or scoringmethod=scoreandevaluate, the number of output table rows to show in a sample of the result set (an integer).
Default behavior: Function returns no sample.
scoringmethod
[Optional] Whether to score (only), evaluate (only), or score and evaluate.
With the options evaluate and scoreandevaluate, the function outputs a confusion matrix table in XML format. The table includes counts of predicted and actual values of the dependent variable of the decision tree model and counts of correct and incorrect predictions.
Default: score