public class LinearRegressionSummary
extends java.lang.Object
implements scala.Serializable
Modifier and Type | Method and Description |
---|---|
double[] |
coefficientStandardErrors()
Standard error of estimated coefficients and intercept.
|
double[] |
devianceResiduals()
The weighted residuals, the usual residuals rescaled by
the square root of the instance weights.
|
double |
explainedVariance() |
java.lang.String |
labelCol() |
double |
meanAbsoluteError()
Returns the mean absolute error, which is a risk function corresponding to the
expected value of the absolute error loss or l1-norm loss.
|
double |
meanSquaredError()
Returns the mean squared error, which is a risk function corresponding to the
expected value of the squared error loss or quadratic loss.
|
LinearRegressionModel |
model() |
long |
numInstances()
Number of instances in DataFrame predictions
|
java.lang.String |
predictionCol() |
DataFrame |
predictions() |
double[] |
pValues()
Two-sided p-value of estimated coefficients and intercept.
|
double |
r2()
Returns R^2^, the coefficient of determination.
|
DataFrame |
residuals()
Residuals (label - predicted value)
|
double |
rootMeanSquaredError()
Returns the root mean squared error, which is defined as the square root of
the mean squared error.
|
double[] |
tValues()
T-statistic of estimated coefficients and intercept.
|
public DataFrame predictions()
public java.lang.String predictionCol()
public java.lang.String labelCol()
public LinearRegressionModel model()
public double explainedVariance()
public double meanAbsoluteError()
Note: This ignores instance weights (setting all to 1.0) from LinearRegression.weightCol
.
This will change in later Spark versions.
public double meanSquaredError()
Note: This ignores instance weights (setting all to 1.0) from LinearRegression.weightCol
.
This will change in later Spark versions.
public double rootMeanSquaredError()
Note: This ignores instance weights (setting all to 1.0) from LinearRegression.weightCol
.
This will change in later Spark versions.
public double r2()
http://en.wikipedia.org/wiki/Coefficient_of_determination
Note: This ignores instance weights (setting all to 1.0) from LinearRegression.weightCol
.
This will change in later Spark versions.
public DataFrame residuals()
public long numInstances()
public double[] devianceResiduals()
public double[] coefficientStandardErrors()
public double[] tValues()
public double[] pValues()