Learn R Programming

hypervolume (version 1.3.0)

hypervolume_thin: Reduces the number of random points in a hypervolume

Description

Many hypervolume algorithms have computational complexities that scale with the number of random points used to characterize a hypervolume (@RandomUniformPointsThresholded). This value can be reduced to improve runtimes at the cost of lower resolution.

Usage

hypervolume_thin(hv, factor = NULL, npoints = NULL)

Arguments

hv
An object of class Hypervolume
factor
A number in (0,1) describing the fraction of random points to keep.
npoints
A number describing the number random points to keep.

Value

  • A Hypervolume object

Details

Either factor or npoints (but not both) must be specified.

Examples

Run this code
data(iris)
hv1 = hypervolume(subset(iris, Species=="setosa")[,1:4],bandwidth=0.2)

# downsample to 1000 random points
hv1_thinned = hypervolume_thin(hv1, npoints=1000)

Run the code above in your browser using DataLab