View source: R/Visualization.R
runUMAP | R Documentation |
Use uwot pacakge since it's more stable in R. Uwot::umap default parameters are from ArchR.
runUMAP( dmat, sdev = NULL, nPC = 30, outpdf = NULL, width = 7, height = 7, xlab = "UMAP-1", ylab = "UMAP-1", title = NULL, color = NULL, ncomp = 2, seed = 10, weightDimReduct = FALSE, umapNeighbors = 30, umapMindist = 0.3, umapMetric = "cosine", umapVerbose = FALSE, umapFastSGD = TRUE, umapNthread = 1, a = NULL, b = NULL, init = "spectral", retnn = FALSE, retmodel = FALSE )
dmat |
matrix, cell by feature |
sdev |
vector, scaling factors for dims, default is NULL |
nPC |
integer, dims till the nPC-th dim will be used for UMAP, default is 30. When nfeature in mat is less than nPC, nfeature will be used. |
outpdf |
string, default is NULL |
width |
double, for outpdf, default is 7 |
height |
double, for outpdf, default is 7 |
xlab |
string, default is "UMAP-1" |
ylab |
string, default is "UMAP-2" |
title |
string, default is NULL |
color |
vector of string or factor, default is NULL |
ncomp |
integer, defaul is 2 |
seed |
integer, default is 10 |
weightDimReduct |
bool, default is FALSE, together used with sdev. |
umapNeighbors |
integer, default is 30 In umot::umap, default is 15. |
umapMindist |
double, default is 0.3 In umot::umap, default is 0.01 |
umapMetric |
string, default is "cosine" NOTE: "euclidean" is the default in uwot::umap |
umapVerbose |
bool, default is FALSE |
umapFastSGD |
bool, default is TRUE |
umapNthread |
integer, default is 1 |
a |
double, default is NULL |
b |
double, default is NULL NOTE: a = 1.8956, b = 0.8006 is the default UMAP |
init |
string, default is "special" NOTE: Use init = "spca" rather than init = "spectral" for better reproducibility (although the latter is the default and preferred method for UMAP initialization). |
retnn |
bool, default is FALSE |
retmodel |
bool, default is FALSE Set both retnn and retmodel as TRUE to save model |
Ref: https://github.com/jlmelville/uwot Ref: https://satijalab.org/seurat/reference/runumap
matrix, cell by ncomp
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.