Sampler | R Documentation |
This is an abstract class for sampling datasets.
label
('character()')
mode
('character()')
new()
Creates a new instance of this R6 class.
Sampler$new(label = NA_character_, mode = c("auto"))
label
The label for the sampler object.
mode
Currently unused member.
Note that this object is typically constructed by a derived class.
fit()
Check inputs and statistics of the sampler. Normally, you should use fit_resample
in all cases.
Sampler$fit(X, y)
X
Feature dataset, usually a data.frame
or an array
.
y
Target dataset, usually a column of a data.frame
or an array
.
A list with X_resampled
and y_resampled
.
Note that this object is typically constructed by a derived class.
fit_resample()
Resample the dataset.
Sampler$fit_resample(X, y)
X
Feature data set, usually a data.frame
or an array
.
y
Target data set, usually a column of a data.frame
or an array
.
A list with X_resampled
and y_resampled
.
Note that this object is typically constructed by a derived class.
clone()
The objects of this class are cloneable with this method.
Sampler$clone(deep = FALSE)
deep
Whether to make a deep clone.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.