Unlabeled datasets can be used to train unsupervised Estimators and for feeding data into an Estimator to make predictions.


# Param Default Type Description
1 samples array A 2-dimensional array consisting of rows of samples and columns with feature values.
2 validate true bool Should we validate the input?

Additional Methods#

Factory Methods#

Build a new unlabeled dataset with validation:

public static build(array $samples = []) : self

Build a new unlabeled dataset foregoing validation:

public static quick(array $samples = []) : self

Build a dataset with an iterator:

public static fromIterator(iterable $samples) : self


use Rubix\ML\Datasets\Unlabeled;

// Import samples

$dataset = new Unlabeled($samples, true);  // Using the constructor

$dataset = Unlabeled::build($samples);  // Build a dataset with validation

$dataset = Unlabeled::quick($samples);  // Build a dataset without validation

$dataset = Unlabeled::fromIterator($samples); // From an iterator