clust_remove: Remove a cluster from an umapscan object

Description Usage Arguments Value Examples

View source: R/clustering.R

Description

If the cluster has children, they will be removed too.

Usage

1
clust_remove(us, id, rm_root = FALSE)

Arguments

us

umapscan object

id

id of the cluster to remove

rm_root

if TRUE, also remove the root cluster node. Otherwise, only remove its children (should not be used directly, only for recursive call).

Value

An updated umapscan object.

Examples

1
2
3
4
5
6
7
8
9
library(dplyr)
iris_num <- iris %>% select_if(is.numeric)
us <- new_umapscan(iris_num, n_neighbors = 25, min_dist = 0.1, seed = 1337)
us <- clust_compute(us, minPts = 3, eps = 0.5)
us <- clust_compute(us, parent = "3" ,minPts = 3, eps = 0.45)
clust_remove(us, "3_1")
us
clust_remove(us, "3")
us

juba/umapscan documentation built on Aug. 29, 2020, 7:31 a.m.