Packages

t

org.apache.spark.ml.classification

LogisticRegressionSummary

sealed trait LogisticRegressionSummary extends ClassificationSummary

Abstraction for logistic regression results for a given model.

Source
LogisticRegression.scala
Linear Supertypes
ClassificationSummary, Serializable, Serializable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. LogisticRegressionSummary
  2. ClassificationSummary
  3. Serializable
  4. Serializable
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def featuresCol: String

    Field in "predictions" which gives the features of each instance as a vector.

    Field in "predictions" which gives the features of each instance as a vector.

    Annotations
    @Since( "1.6.0" )
  2. abstract def labelCol: String

    Field in "predictions" which gives the true label of each instance (if available).

    Field in "predictions" which gives the true label of each instance (if available).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  3. abstract def predictionCol: String

    Field in "predictions" which gives the prediction of each class.

    Field in "predictions" which gives the prediction of each class.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  4. abstract def predictions: DataFrame

    Dataframe output by the model's transform method.

    Dataframe output by the model's transform method.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  5. abstract def probabilityCol: String

    Field in "predictions" which gives the probability of each class as a vector.

    Field in "predictions" which gives the probability of each class as a vector.

    Annotations
    @Since( "1.5.0" )
  6. abstract def weightCol: String

    Field in "predictions" which gives the weight of each instance.

    Field in "predictions" which gives the weight of each instance.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )

Concrete Value Members

  1. def accuracy: Double

    Returns accuracy.

    Returns accuracy. (equals to the total number of correctly classified instances out of the total number of instances.)

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  2. def asBinary: BinaryLogisticRegressionSummary

    Convenient method for casting to binary logistic regression summary.

    Convenient method for casting to binary logistic regression summary. This method will throw an Exception if the summary is not a binary summary.

    Annotations
    @Since( "2.3.0" )
  3. def fMeasureByLabel: Array[Double]

    Returns f1-measure for each label (category).

    Returns f1-measure for each label (category).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  4. def fMeasureByLabel(beta: Double): Array[Double]

    Returns f-measure for each label (category).

    Returns f-measure for each label (category).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  5. def falsePositiveRateByLabel: Array[Double]

    Returns false positive rate for each label (category).

    Returns false positive rate for each label (category).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  6. def labels: Array[Double]

    Returns the sequence of labels in ascending order.

    Returns the sequence of labels in ascending order. This order matches the order used in metrics which are specified as arrays over labels, e.g., truePositiveRateByLabel.

    Note: In most cases, it will be values {0.0, 1.0, ..., numClasses-1}, However, if the training set is missing a label, then all of the arrays over labels (e.g., from truePositiveRateByLabel) will be of length numClasses-1 instead of the expected numClasses.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  7. def precisionByLabel: Array[Double]

    Returns precision for each label (category).

    Returns precision for each label (category).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  8. def recallByLabel: Array[Double]

    Returns recall for each label (category).

    Returns recall for each label (category).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  9. def truePositiveRateByLabel: Array[Double]

    Returns true positive rate for each label (category).

    Returns true positive rate for each label (category).

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  10. def weightedFMeasure: Double

    Returns weighted averaged f1-measure.

    Returns weighted averaged f1-measure.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  11. def weightedFMeasure(beta: Double): Double

    Returns weighted averaged f-measure.

    Returns weighted averaged f-measure.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  12. def weightedFalsePositiveRate: Double

    Returns weighted false positive rate.

    Returns weighted false positive rate.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  13. def weightedPrecision: Double

    Returns weighted averaged precision.

    Returns weighted averaged precision.

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  14. def weightedRecall: Double

    Returns weighted averaged recall.

    Returns weighted averaged recall. (equals to precision, recall and f-measure)

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )
  15. def weightedTruePositiveRate: Double

    Returns weighted true positive rate.

    Returns weighted true positive rate. (equals to precision, recall and f-measure)

    Definition Classes
    ClassificationSummary
    Annotations
    @Since( "3.1.0" )