mirror of
https://github.com/Llewellynvdm/php-ml.git
synced 2024-06-05 18:10:47 +00:00
d85bfed468
* [cs] remove more unused comments * [cs] remove unused array phpdocs * [cs] remove empty lines in docs * [cs] space-proof useless docs * [cs] remove empty @param lines * [cs] remove references arrays
20 lines
356 B
PHP
20 lines
356 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Phpml\Preprocessing\Imputer\Strategy;
|
|
|
|
use Phpml\Math\Statistic\Mean;
|
|
use Phpml\Preprocessing\Imputer\Strategy;
|
|
|
|
class MostFrequentStrategy implements Strategy
|
|
{
|
|
/**
|
|
* @return float|mixed
|
|
*/
|
|
public function replaceValue(array $currentAxis)
|
|
{
|
|
return Mean::mode($currentAxis);
|
|
}
|
|
}
|