Description Usage Arguments Author(s) Examples
Given a Seurat seurat and a data frame where the rows correspond to cells, in the same order as in the Seurat seurat, add two columns giving coordinates in a dimensionality reduced space.
| 1 | addEmbedding(seurat, df, reduction = "tsne", dim1 = 1, dim2 = 2)
 | 
| seurat | Seurat object, where dimensionality reduction has been applied, i.e. (after applying Seurat::RunPCA() or Seurat::RunTSNE() to the object). | 
| df | Data frame with at least one column, "Cell", giving the cell ID | 
| reduction | String specifying the dimensionality reduction to use, retrieves t-SNE by default. This should match the names of the elements of the list seurat@dr, so it will typically be one of "pca" or "tsne". Default: "tsne" | 
Selin Jessa
| 1 2 3 4 | df <- data.frame(Cell = rownames(pbmc@meta.data),
                 Cluster = pbmc@meta.data$res.1)
addEmbedding(pbmc, df, reduction = "tsne")
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.