public function predict(Dataset $dataset) : array
    {
        if (!$this->trained) {
            throw new RuntimeException('The learner has not'
                . ' been trained.');
        }
        
        $n = $dataset->numRows();

        $predictions = [];

        for ($i = 0; $i < $n; $i++) {
            $predictions[] = $this->strategy->guess();
        }

        return $predictions;
    }
public function predict(Dataset $dataset) : array
    {
        if (!$this->trained) {
            throw new RuntimeException('The learner has not'
                . ' been trained.');
        }
        
        $n = $dataset->numRows();

        $predictions = [];

        for ($i = 0; $i < $n; $i++) {
            $predictions[] = $this->strategy->guess();
        }

        return $predictions;
    }
public function predict ( Dataset $ dataset ) : array { if ( ! $ this -> trained ) { throw new RuntimeException ( 'The learner has not' . ' been trained.' ) ; } $ n = $ dataset -> numRows ( ) ; $ predictions = [ ] ; for ( $ i = 0 ; $ i < $ n ; $ i ++ ) { $ predictions [ ] = $ this -> strategy -> guess ( ) ; } return $ predictions ; }
Make a prediction of a given sample dataset.

@param \Rubix\ML\Datasets\Dataset $dataset
@return array
Make a prediction of a given sample dataset .