copy_param_hypervolume: Generate hypervolumes using pre-existing parameters

Description Usage Arguments Details Value Examples

View source: R/copy_param_hypervolume.R

Description

copy_param_hypervolume takes in a hypervolume and data. After detecting the method used to generate the input hypervolume, the function returns a new hypervolume generated from the data using the same method and parameters as the input hypervolume.

Usage

1

Arguments

hv

hypervolume object

data

A m x n matrix or data frame, where m is the number of observations and n is the dimensionality.

name

String name of hypervolume

Details

copy_param_hypervolume only works if the input hypervolume was generated using method = "box", method = "gaussian", or method = "svm". Calling this function on hypervolumes generated from hypervolume_set will result in an error. Note that kde.bandwidth is affected by size of the data and will be copied when method = "gaussian". Use hv@Parameters to see what parameters are copied from the input hypervolume.

Value

hypervolume object

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 
data("iris")
hv = hypervolume(iris[,c(1,2)], 
                  method = "gaussian", 
                  quantile.requested = .9, 
                  quantile.requested.type = "volume")

# Generates a new hypervolume using the same hypervolume and data
hv_copy = copy_param_hypervolume(hv, hv@Data)
# Check to see that the information of the two hypervolumes is the same
print(hv)
print(hv_copy)

## End(Not run)

dc165/Hypervolume-Dev documentation built on Dec. 13, 2020, 6:02 p.m.