-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #192 from zhanghao-njmu/develop
Develop
- Loading branch information
Showing
10 changed files
with
48 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2763,12 +2763,13 @@ FeatureDimPlot <- function(srt, features, reduction = NULL, dims = c(1, 2), spli | |
#' Plotting cell points on a reduced 3D space and coloring according to the groups of the cells. | ||
#' | ||
#' @inheritParams CellDimPlot | ||
#' @param dims Dimensions to plot, must be a three-length numeric vector specifying x-, y- and z-dimensions | ||
#' @param axis_labs A character vector of length 3 indicating the labels for the axes. | ||
#' @param span A numeric value specifying the span of the loess smoother for lineages line. | ||
#' @param shape.highlight Shape of the cell to highlight. See \href{https://plotly.com/r/reference/scattergl/#scattergl-marker-symbol}{scattergl-marker-symbol} | ||
#' @param width Width in pixels, defaults to automatic sizing. | ||
#' @param height Height in pixels, defaults to automatic sizing. | ||
#' @param save The name of the file to save the plot to. Must end in .html. | ||
#' @param save The name of the file to save the plot to. Must end in ".html". | ||
#' @seealso \code{\link{CellDimPlot}} \code{\link{FeatureDimPlot3D}} | ||
#' | ||
#' @examples | ||
|
@@ -2778,6 +2779,7 @@ FeatureDimPlot <- function(srt, features, reduction = NULL, dims = c(1, 2), spli | |
#' | ||
#' pancreas_sub <- RunSlingshot(pancreas_sub, group.by = "SubCellType", reduction = "StandardpcaUMAP3D") | ||
#' CellDimPlot3D(pancreas_sub, group.by = "SubCellType", reduction = "StandardpcaUMAP3D", lineages = "Lineage1") | ||
#' | ||
#' @importFrom Seurat Reductions Embeddings Key | ||
#' @importFrom utils askYesNo | ||
#' @importFrom plotly plot_ly add_trace layout as_widget | ||
|
@@ -2857,9 +2859,6 @@ CellDimPlot3D <- function(srt, group.by, reduction = NULL, dims = c(1, 2, 3), ax | |
dat_lineages <- [email protected][, unique(lineages), drop = FALSE] | ||
dat_use <- cbind(dat_use, dat_lineages[row.names(dat_use), , drop = FALSE]) | ||
} | ||
if (!is.factor(dat_use[[group.by]])) { | ||
dat_use[[group.by]] <- factor(dat_use[[group.by]], levels = unique(dat_use[[group.by]])) | ||
} | ||
dat_use[["group.by"]] <- dat_use[[group.by]] | ||
if (any(is.na(dat_use[[group.by]]))) { | ||
n <- as.character(dat_use[[group.by]]) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.