Skip to contents

Creates a UMAP plot colored by cluster assignments.

Usage

plot_umap(
  umap_coords,
  clusters,
  title = "UMAP Visualization",
  point_size = 2,
  colors = NULL,
  show_legend = TRUE
)

Arguments

umap_coords

UMAP coordinates from compute_umap().

clusters

Vector of cluster assignments or data frame with Cluster column.

title

Plot title (default: "UMAP Visualization").

point_size

Point size (default: 2).

colors

Custom color palette (optional).

show_legend

Show legend (default: TRUE).

Value

A ggplot object if ggplot2 is available, otherwise base R plot.