
Plots the expression profile of a feature set corresponding to specified pathways onto a 2D scatter plot based on a dimensionality reduction technique.
Source:R/PathwayVisualisation.R
PlotSinglePathway.RdNOTE: This is a helper function for PlotPathways. This function has been adapted from fgsea package. For more detail about function inputs please visit their documentation.
Usage
PlotSinglePathway(
pathway,
object,
title = NULL,
assay = DefaultAssay(object),
slot = "scale.data",
reduction = NULL,
colors = c("darkblue", "lightgrey", "darkred"),
guide = "colourbar",
...
)Arguments
- pathway
Character vector of pathway names to plot. These pathways must be those stored in the
chempathwayobject. To check callunique(chempathway$pathwayName).- object
SpaMTP Seurat object containing the spatial data and coordinates for plotting.
- title
Optional title for the plot. If set to
NULLthe title will be the pathway name (default = NULL).- assay
Character string defining the name of assay to use for data extraction. This
assayshould contain RAMP_IDs as feature names (default =SeuratObject::DefaultAssay(object)).- slot
Character string defining the name of slot to extract data from (default = "scale.data").
- reduction
Character string defining which dimensionality reduction to use. If not specified, first searches for 'umap', then 'tsne', then 'pca' (default = NULL).
- colors
Vector of colors for the gradient (default = c("darkblue", "lightgrey", "darkred")).
- guide
Character string stating the type of legend to display (default = "colourbar").
- ...
Additional inputs taken by
Seurat::FeaturePlot(). Check the relative documentation for more infomation.