Learn R Programming

hypervolume (version 3.1.4)

get_centroid: Get centroid of hypervolume or hypervolume list

Description

Returns the column mean of the random points in each hypervolume.

Usage

get_centroid(hv)

Value

Either a vector or a matrix of column of centroid values along each axis.

Arguments

hv

A Hypervolume or HypervolumeList object.

Examples

Run this code
if (FALSE) {
data(penguins,package='palmerpenguins')
penguins_no_na = as.data.frame(na.omit(penguins))
penguins_adelie = penguins_no_na[penguins_no_na$species=="Adelie",
                    c("bill_length_mm","bill_depth_mm","flipper_length_mm")]
hv = hypervolume_gaussian(penguins_adelie)
get_centroid(hv)
}

Run the code above in your browser using DataLab