create_umap: Create a UMAP data.frame from a result object

Description Usage Arguments Value Examples

View source: R/plotting.R

Description

Create a UMAP data.frame from a result object

Usage

1
2
3
4
5
6
7
8
9
create_umap(
  result,
  annotation,
  n_neighbors = 30,
  min_dist = 0.75,
  spread = 1,
  proportional = TRUE,
  seed = FALSE
)

Arguments

result

S4 Result Object

annotation

Annotation to use for umap coloring

n_neighbors

The size of local neighborhood used for views of manifold approximation. Larger values result in more global the manifold, while smaller values result in more local data being preserved. Default 30. See '?uwot::umap' for more information.

min_dist

The effective minimum distance between embedded points. Smaller values will result in a more clustered/clumped embedding where nearby points on the manifold are drawn closer together, while larger values will result on a more even dispersal of points. Default 0.2. See '?uwot::umap' for more information.

spread

The effective scale of embedded points. In combination with ‘min_dist’, this determines how clustered/clumped the embedded points are. Default 1. See '?uwot::umap' for more information.

proportional

Whether weights are normalized to sum to 1 or not

seed

Use a seed for reproducible results

Value

UMAP data.frame

Examples

1
2
3
4
result <- readRDS(system.file("testdata", "res_annot.rds",
package = "BAGEL"))
BAGEL::create_umap(result = result, annotation = "Tumor_Subtypes",
n_neighbors = 5)

campbio/BAGEL documentation built on Oct. 6, 2020, 3:59 a.m.