◆ __construct()
Phpml\Classification\KNearestNeighbors::__construct |
( |
int | $k = 3, |
|
|
?Distance | $distanceMetric = null ) |
- Parameters
-
Distance | null | $distanceMetric | (if null then Euclidean distance as default) |
◆ predict()
Phpml\Estimator::predict |
( |
array | $samples | ) |
|
|
inherited |
◆ predictSample()
Phpml\Classification\KNearestNeighbors::predictSample |
( |
array | $sample | ) |
|
|
protected |
◆ train()
Phpml\Estimator::train |
( |
array | $samples, |
|
|
array | $targets ) |
|
inherited |
The documentation for this class was generated from the following file:
- lib/mlbackend/php/phpml/src/Phpml/Classification/KNearestNeighbors.php