KNeighborsClassifier class
An implementation of sklearn.neighbors.KNeighborsClassifier
https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KNeighborsClassifier.html
- Inheritance
-
- Object
- Classifier
- KNeighborsClassifier
Constructors
-
KNeighborsClassifier(List<
List> fitX, List<int> fitY, int nNeighbors, int p, List<int> classes) - To manually instantiate the KNeighborsClassifier. The parameters are lifted directly from scikit-learn. See the attributes here: https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KNeighborsClassifier.html
-
KNeighborsClassifier.fromMap(Map<
String, dynamic> params) -
factory
Properties
-
classes
↔ List<
int> -
getter/setter pair
-
fitX
↔ List<
List> -
getter/setter pair
-
fitY
↔ List<
int> -
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- nNeighbors ↔ int
-
getter/setter pair
- p ↔ int
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
cmp(
List temp, List cand, int q) → double -
fromURL(
String url) → dynamic -
Override in all classes extending Classifier.
Load a model from a URL using an HTTP request
@TODO
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
predict(
List< double> X) → int -
Implementation of sklearn.neghbors.KNeighborsClassifier.predict.
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited