public function leave(int $n = 1) : self
    {
        if ($n < 0) {
            throw new InvalidArgumentException('Cannot leave less than 0 samples.');
        }

        return $this->splice($n, $this->numRows());
    }
public function leave(int $n = 1) : self
    {
        if ($n < 0) {
            throw new InvalidArgumentException('Cannot leave less than 0 samples.');
        }

        return $this->splice($n, $this->numRows());
    }
public function leave ( int $ n = 1 ) : self { if ( $ n < 0 ) { throw new InvalidArgumentException ( 'Cannot leave less than 0 samples.' ) ; } return $ this -> splice ( $ n , $ this -> numRows ( ) ) ; }
Leave n samples and labels on this dataset and return the rest in a new
dataset.

@param int $n
@throws \InvalidArgumentException
@return self
Leave n samples and labels on this dataset and return the rest in a new dataset .