> pbmc <- RunUMAP(object = pbmc, reduction = 'lsi', dims = 2:15)
22:05:19 UMAP embedding parameters a = 0.9922 b = 1.112
22:05:19 Read 16 rows and found 14 numeric columns
Error in uwot(X = X, n_neighbors = n_neighbors, n_components = n_components, :
n_neighbors must be smaller than the dataset size
#错误原因,没有这么多的维度,所以需要将n.neighbors设置小一点,n.neighbors默认是30
pbmc <- RunUMAP(object = pbmc, reduction = 'lsi', dims = 2:15,n.neighbors=15)#即可正常运行