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

Vantage Analytics Library User Guide

Deployment
VantageCloud
VantageCore
Edition
VMware
Enterprise
IntelliFlex
Lake
Product
Vantage Analytics Library
Release Number
2.2.0
Published
June 2025
ft:locale
en-US
ft:lastEdition
2025-07-02
dita:mapPath
ibw1595473364329.ditamap
dita:ditavalPath
iup1603985291876.ditaval
dita:id
zyl1473786378775
Product Category
Teradata Vantage

Using a model built by the linear function, the linearscore function scores new data—that is, it estimates the value of the dependent variable in the model using data for which its value may be unknown.

Scoring uses the values of the b-coefficients in the linear regression model and the names of their corresponding independent variable columns.

The function outputs a new table containing primary index columns, the estimated value of the dependent variable, and (optionally) a residual value for each row. The residual value is the difference between the estimated and actual values of the dependent variable.

The columns in tablename are the same as the columns in the table from which the linear function built the model, except that tablename need not include the predicted or dependent variable column if scoringmethod=score.

Evaluation

The linearscore function uses these steps to evaluate a model:
  1. Score a table that includes the actual values of the dependent variable.
  2. Calculate and report the standard error of estimate for the model.
  3. Compare the calculated standard error of estimate with the standard error of estimate reported when the model was built.

The function calculates the standard error of estimate with the following formula, where:

Term Description
"" Actual value of dependent variable.
y Predicted value of dependent variable.
n Number of observations.
p Number of independent variables.

Standard error of estimate formula

If there is no constant term, the function substitutes n-p for n-p-1 in the formula.