Metabolic landscape analysis for scRNA-seq data
MetabolicPathwayActivity
(Proc) — This process calculates the pathway activities in different groups and subsets.</>MetabolicFeatures
(Proc) — This process performs enrichment analysis for the metabolic pathwaysfor each group in each subset. </>MetabolicFeaturesIntraSubset
(Proc) — Intra-subset metabolic features - Enrichment analysis in details</>MetabolicPathwayHeterogeneity
(Proc) — Calculate Metabolic Pathway heterogeneity.</>ScrnaMetabolicLandscape
— Metabolic landscape analysis for scRNA-seq data</>
biopipen.ns.scrna_metabolic_landscape.
MetabolicPathwayActivity
(
*args
, **kwds
)
→ Proc
This process calculates the pathway activities in different groups and subsets.
The cells are first grouped by subsets and then the metabolic activities are examined for each groups in different subsets.
For each subset, a heatmap and a violin plot will be generated. The heatmap shows the pathway activities for each group and each metabolic pathway
{: width="80%"}
The violin plot shows the distribution of the pathway activities for each group
{: width="45%"}
gmtfile
(pgarg) — The GMT file with the metabolic pathways.Defaults toScrnaMetabolicLandscape.gmtfile
grouping
(type=auto;pgarg;readonly) — Defines the basic groups toinvestigate the metabolic activity, typically the clusters. Defaults toScrnaMetabolicLandscape.grouping
grouping_prefix
(type=auto;pgarg;readonly) — Working as a prefix to groupnames. For example, if we havegrouping_prefix = "cluster"
and we have1
and2
in thegrouping
column, the groups will be named ascluster_1
andcluster_2
. Defaults toScrnaMetabolicLandscape.grouping_prefix
heatmap_devpars
(ns) — Device parameters for the heatmapwidth
(type=int): Width of the heatmapheight
(type=int): Height of the heatmapres
(type=int): Resolution of the heatmap
ncores
(type=int;pgarg) — Number of cores to use for parallelizationDefaults toScrnaMetabolicLandscape.ncores
ntimes
(type=int) — Number of times to do the permutationsubsetting
(type=auto;pgarg;readonly) — How do we subset the data. Othercolumns in the metadata to do comparisons. For example,"TimePoint"
or["TimePoint", "Response"]
. Defaults toScrnaMetabolicLandscape.subsetting
subsetting_prefix
(type=auto;pgarg;readonly) — Working as a prefix tosubset names. For example, if we havesubsetting_prefix = "timepoint"
and we havepre
andpost
in thesubsetting
column, the subsets will be named astimepoint_pre
andtimepoint_post
. Ifsubsetting
is a list, then this should also be a same-length list. If a single string is given, it will be repeated to a list with the same length assubsetting
. Defaults toScrnaMetabolicLandscape.subsetting_prefix
violin_devpars
(ns) — Device parameters for the violin plotwidth
(type=int): Width of the violin plotheight
(type=int): Height of the violin plotres
(type=int): Resolution of the violin plot
r-complexheatmap
—- check: {{proc.lang}} <(echo "library(ComplexHeatmap)")
r-ggplot2
—- check: {{proc.lang}} <(echo "library(ggplot2)")
r-ggprism
—- check: {{proc.lang}} <(echo "library(ggprism)")
r-parallel
—- check: {{proc.lang}} <(echo "library(parallel)")
r-rcolorbrewer
—- check: {{proc.lang}} <(echo "library(RColorBrewer)")
r-reshape2
—- check: {{proc.lang}} <(echo "library(reshape2)")
r-scater
—- check: {{proc.lang}} <(echo "library(scater)")
biopipen.ns.scrna_metabolic_landscape.
MetabolicFeatures
(
*args
, **kwds
)
→ Proc
fgsea
(flag) — Whether to do fast gsea analysis usingfgsea
package.IfFalse
, theGSEA_R
package will be used.gmtfile
(pgarg) — The GMT file with the metabolic pathways.Defaults toScrnaMetabolicLandscape.gmtfile
grouping
(type=auto;pgarg;readonly) — Defines the basic groups toinvestigate the metabolic activity. Defaults toScrnaMetabolicLandscape.grouping
grouping_prefix
(type=auto;pgarg;readonly) — Working as a prefix togroup names. Defaults toScrnaMetabolicLandscape.grouping_prefix
ncores
(type=int;pgarg) — Number of cores to use for parallelization.Defaults toScrnaMetabolicLandscape.ncores
prerank_method
(choice) — Method to use for gene preranking.Signal to noise: the larger the differences of the means (scaled by the standard deviations); that is, the more distinct the gene expression is in each phenotype and the more the gene acts as a “class marker.”. Absolute signal to noise: the absolute value of the signal to noise. T test: Uses the difference of means scaled by the standard deviation and number of samples. Ratio of classes: Uses the ratio of class means to calculate fold change for natural scale data. Diff of classes: Uses the difference of class means to calculate fold change for nature scale data Log2 ratio of classes: Uses the log2 ratio of class means to calculate fold change for natural scale data. This is the recommended statistic for calculating fold change for log scale data.signal_to_noise
: Signal to noises2n
: Alias of signal_to_noiseabs_signal_to_noise
: absolute signal to noiseabs_s2n
: Alias of abs_signal_to_noiset_test
: T testratio_of_classes
: Also referred to as fold changediff_of_classes
: Difference of class meanslog2_ratio_of_classes
: Log2 ratio of class means
subsetting
(type=auto;pgarg;readonly) — How do we subset the data.Another column(s) in the metadata. Defaults toScrnaMetabolicLandscape.subsetting
subsetting_prefix
(type=auto;pgarg;readonly) — Working as a prefix tosubset names. Defaults toScrnaMetabolicLandscape.subsetting_prefix
top
(type=int) — N top of enriched pathways to show
r-fgsea
—- check: {{proc.lang}} <(echo "library(fgsea)")
r-parallel
—- check: {{proc.lang}} <(echo "library(parallel)")
biopipen.ns.scrna_metabolic_landscape.
MetabolicFeaturesIntraSubset
(
*args
, **kwds
)
→ Proc
Intra-subset metabolic features - Enrichment analysis in details
Similar to the MetabolicFeatures
process, this process performs enrichment analysis for the metabolic pathways for
each subset in each group, instead of each group in each subset.
fgsea
(flag) — Whether to do fast gsea analysisgmtfile
(pgarg) — The GMT file with the metabolic pathways.Defaults toScrnaMetabolicLandscape.gmtfile
grouping
(type=auto;pgarg;readonly) — Defines the basic groups toinvestigate the metabolic activity. Defaults toScrnaMetabolicLandscape.grouping
grouping_prefix
(type=auto;pgarg;readonly) — Working as a prefix to groupnames. Defaults toScrnaMetabolicLandscape.grouping_prefix
ncores
(type=int; pgarg) — Number of cores to use for parallelizationDefaults toScrnaMetabolicLandscape.ncores
prerank_method
(choice) — Method to use for gene prerankingSignal to noise: the larger the differences of the means (scaled by the standard deviations); that is, the more distinct the gene expression is in each phenotype and the more the gene acts as a “class marker.”. Absolute signal to noise: the absolute value of the signal to noise. T test: Uses the difference of means scaled by the standard deviation and number of samples. Ratio of classes: Uses the ratio of class means to calculate fold change for natural scale data. Diff of classes: Uses the difference of class means to calculate fold change for nature scale data Log2 ratio of classes: Uses the log2 ratio of class means to calculate fold change for natural scale data. This is the recommended statistic for calculating fold change for log scale data.signal_to_noise
: Signal to noises2n
: Alias of signal_to_noiseabs_signal_to_noise
: absolute signal to noiseabs_s2n
: Alias of abs_signal_to_noiset_test
: T testratio_of_classes
: Also referred to as fold changediff_of_classes
: Difference of class meanslog2_ratio_of_classes
: Log2 ratio of class means
subsetting
(type=auto;pgarg;readonly) — How do we subset the data.Another column(s) in the metadata. Defaults toScrnaMetabolicLandscape.subsetting
subsetting_comparison
(type=json;pgarg;readonly) — How do we compare thesubsets. Defaults toScrnaMetabolicLandscape.subsetting_comparison
subsetting_prefix
(type=auto;pgarg;readonly) — Working as a prefix tosubset names. Defaults toScrnaMetabolicLandscape.subsetting_prefix
top
(type=int) — N top of enriched pathways to show
r-fgsea
—- check: {{proc.lang}} <(echo "library(fgsea)")
r-parallel
—- check: {{proc.lang}} <(echo "library(parallel)")
r-scater
—- check: {{proc.lang}} <(echo "library(scater)")
biopipen.ns.scrna_metabolic_landscape.
MetabolicPathwayHeterogeneity
(
*args
, **kwds
)
→ Proc
Calculate Metabolic Pathway heterogeneity.
For each subset, the normalized enrichment score (NES) of each metabolic pathway is calculated for each group. The NES is calculated by comparing the enrichment score of the subset to the enrichment scores of the same subset in the permutations. The p-value is calculated by comparing the NES to the NESs of the same subset in the permutations. The heterogeneity can be reflected by the NES values and the p-values in different groups for the metabolic pathways.
bubble_devpars
(ns) — The devpars for the bubble plotwidth
(type=int): The width of the plotheight
(type=int): The height of the plotres
(type=int): The resolution of the plot
gmtfile
(pgarg) — The GMT file with the metabolic pathways.Defaults toScrnaMetabolicLandscape.gmtfile
grouping
(type=auto;pgarg;readonly) — Defines the basic groups toinvestigate the metabolic activity. Defaults toScrnaMetabolicLandscape.grouping
grouping_prefix
(type=auto;pgarg;readonly) — Working as a prefix to groupnames. Defaults toScrnaMetabolicLandscape.grouping_prefix
ncores
(type=int;pgarg) — Number of cores to use for parallelizationDefaults toScrnaMetabolicLandscape.ncores
pathway_pval_cutoff
(type=float) — The p-value cutoff to selectthe enriched pathwaysselect_pcs
(type=float) — Select the PCs to use for the analysis.subsetting
(type=auto;pgarg;readonly) — How do we subset the data.Another column(s) in the metadata. Defaults toScrnaMetabolicLandscape.subsetting
subsetting_prefix
(type=auto;pgarg;readonly) — Working as a prefix tosubset names. Defaults toScrnaMetabolicLandscape.subsetting_prefix
r-data.table
—- check: {{proc.lang}} <(echo "library(data.table)")
r-dplyr
—- check: {{proc.lang}} <(echo "library(dplyr)")
r-enrichr
—- check: {{proc.lang}} <(echo "library(enrichR)")
r-fgsea
—- check: {{proc.lang}} <(echo "library(fgsea)")
r-ggplot2
—- check: {{proc.lang}} <(echo "library(ggplot2)")
r-ggprism
—- check: {{proc.lang}} <(echo "library(ggprism)")
r-gtools
—- check: {{proc.lang}} <(echo "library(gtools)")
r-parallel
—- check: {{proc.lang}} <(echo "library(parallel)")
r-tibble
—- check: {{proc.lang}} <(echo "library(tibble)")
biopipen.ns.scrna_metabolic_landscape.
ScrnaMetabolicLandscape
(
*args
, **kwds
)
Metabolic landscape analysis for scRNA-seq data
An abstract from https://github.com/LocasaleLab/Single-Cell-Metabolic-Landscape
See docs here for more details https://pwwang.github.io/biopipen/pipelines/scrna_metabolic_landscape
Reference: Xiao, Zhengtao, Ziwei Dai, and Jason W. Locasale. "Metabolic landscape of the tumor microenvironment at single cell resolution." Nature communications 10.1 (2019): 1-12.