Description Details Public fields Methods
Simulate a data set with multiple features
Simulate a data set with multiple features
simulating a dataset with more than one feature requires some logic sampling
features
the feature names
classes
the class names
weights
the relative weights of each distribution
dists
the distribution as Distribution objects
withConditionalDistribution()
adds in a ConditionalDistribution with a class name
MultivariableDistribution$withConditionalDistribution( distribution, featureName )
distribution
the pdf as an R6 ConditionalDistribution object (ConditionalDistribution$new(fn, fnParams...))
featureName
the class name
withClassWeights()
sets the relative weights of the different outcome classes in the simulation
MultivariableDistribution$withClassWeights(listWeights)
listWeights
the weights as a named list e.g. list(feature1 = 0.1, ...)
sample()
produce a set of samples conforming to these distributions
MultivariableDistribution$sample(n = 1000)
n
the number of samples
a data frame of samples (labelled x) associated with classes (labelled "class")
plot()
plot this distributions as pdf and cdf
MultivariableDistribution$plot()
xmin
- the minimum of the support
xmax
- the maximum of the support
a ggassemble plot object
clone()
The objects of this class are cloneable with this method.
MultivariableDistribution$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.