|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object org.apache.spark.ml.PipelineStage org.apache.spark.ml.Estimator<M> org.apache.spark.ml.Predictor<FeaturesType,E,M> org.apache.spark.ml.classification.Classifier<FeaturesType,E,M> org.apache.spark.ml.classification.LogisticRegression
public class LogisticRegression
:: Experimental :: Logistic regression. Currently, this class only supports binary classification.
Constructor Summary | |
---|---|
LogisticRegression()
|
|
LogisticRegression(String uid)
|
Method Summary | |
---|---|
LogisticRegression |
copy(ParamMap extra)
Creates a copy of this instance with the same UID and some extra params. |
LogisticRegression |
setElasticNetParam(double value)
Set the ElasticNet mixing parameter. |
LogisticRegression |
setFitIntercept(boolean value)
Whether to fit an intercept term. |
LogisticRegression |
setMaxIter(int value)
Set the maximum number of iterations. |
E |
setProbabilityCol(String value)
|
LogisticRegression |
setRegParam(double value)
Set the regularization parameter. |
LogisticRegression |
setThreshold(double value)
|
LogisticRegression |
setTol(double value)
Set the convergence tolerance of iterations. |
String |
uid()
|
StructType |
validateAndTransformSchema(StructType schema,
boolean fitting,
DataType featuresDataType)
|
StructType |
validateAndTransformSchema(StructType schema,
boolean fitting,
DataType featuresDataType)
Validates and transforms the input schema with the provided param map. |
Methods inherited from class org.apache.spark.ml.classification.Classifier |
---|
setRawPredictionCol |
Methods inherited from class org.apache.spark.ml.Predictor |
---|
fit, setFeaturesCol, setLabelCol, setPredictionCol, transformSchema |
Methods inherited from class org.apache.spark.ml.Estimator |
---|
fit, fit, fit, fit |
Methods inherited from class Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.spark.Logging |
---|
initializeIfNecessary, initializeLogging, isTraceEnabled, log_, log, logDebug, logDebug, logError, logError, logInfo, logInfo, logName, logTrace, logTrace, logWarning, logWarning |
Methods inherited from interface org.apache.spark.ml.param.Params |
---|
clear, copyValues, defaultCopy, defaultParamMap, explainParam, explainParams, extractParamMap, extractParamMap, get, getDefault, getOrDefault, getParam, hasDefault, hasParam, isDefined, isSet, paramMap, params, set, set, set, setDefault, setDefault, setDefault, shouldOwn, validateParams |
Constructor Detail |
---|
public LogisticRegression(String uid)
public LogisticRegression()
Method Detail |
---|
public String uid()
public LogisticRegression setRegParam(double value)
value
- (undocumented)
public LogisticRegression setElasticNetParam(double value)
value
- (undocumented)
public LogisticRegression setMaxIter(int value)
value
- (undocumented)
public LogisticRegression setTol(double value)
value
- (undocumented)
public LogisticRegression setFitIntercept(boolean value)
value
- (undocumented)
public LogisticRegression setThreshold(double value)
public LogisticRegression copy(ParamMap extra)
Params
copy
in interface Params
copy
in class Predictor<Vector,LogisticRegression,LogisticRegressionModel>
extra
- (undocumented)
defaultCopy()
public StructType validateAndTransformSchema(StructType schema, boolean fitting, DataType featuresDataType)
public E setProbabilityCol(String value)
public StructType validateAndTransformSchema(StructType schema, boolean fitting, DataType featuresDataType)
schema
- input schemafitting
- whether this is in fittingfeaturesDataType
- SQL DataType for FeaturesType.
E.g., VectorUDT
for vector features.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |