Title: | BioPathNet: Three Pod Analysis System |
---|---|
Description: | This package aims to provide a simple interface to perform the Three Pod Analysis of RNASeq dataaset. In addition, this also provides utility functions to perform the individual components. |
Authors: | Ali Sajid Imami [aut, cre] , Khaled Alganem [aut] , Xiaolu Zhang [aut] , Marissa Ann Smail [aut] |
Maintainer: | Ali Sajid Imami <[email protected]> |
License: | GPL-3 |
Version: | 0.2.0 |
Built: | 2024-10-27 04:55:45 UTC |
Source: | https://github.com/CogDisResLab/BioPathNet |
Construct a BPNList object
BPNList(input, gsea, enrichr, ilincs, leading, revigo, integrated)
BPNList(input, gsea, enrichr, ilincs, leading, revigo, integrated)
input |
tbl_df A tibble with the differentially expressed genes |
gsea |
GSEAResult An object containing the GSEA results |
enrichr |
EnrichRResult An object containing the EnrichR results |
ilincs |
iLINCSResult An object containing the iLINCS results |
leading |
LEResult An object containing the Leading Edge Analysis results |
revigo |
RevigoResult An object containing the Revigo results |
integrated |
IntegratedResult An object containing the Integrated results |
A BPNList object
TRUE
TRUE
This class takes care of the entire analysis infrastructure of the BioPathNet analysis. This class is created with inputting a list of differentially expressed genes and then stores the subsequently generated results.
An object of class BPNList
input
tbl_df. A tibble with Two columns of gene names and logfc values and optionally a p-value column
gsea
GSEAResult. An instance of GSEAResult-class class storing the results GSEA Analysis
enrichr
EnrichRResult. An instance of EnrichRResult-class class storing the results EnrichR Analysis
ilincs
iLINCSResult. An instance of iLINCSResult-class class storing the results iLINCS Analysis
leading
LEResult. An instance of LEResult-class class storing the results Leading Edge Analysis
revigo
RevigoResult. An instance of RevigoResult-class class storing the results Revigo Analysis
integrated
IntegratedResult. An instance of IntegratedResult-class class storing the results after integrating the three components
TRUE
TRUE
This function takes in a BPNList object and returns a BPNList object with the enrichr slot updated with process EnrichR Results
do_enrichr_pod(bpn, alpha = 0.05, lower = NULL, upper = NULL, useFDR = TRUE)
do_enrichr_pod(bpn, alpha = 0.05, lower = NULL, upper = NULL, useFDR = TRUE)
bpn |
BPNList An object of class BPNList created from prepare_data |
alpha |
numeric The Alpha value for statistical significance. Defaults to 0.05. |
lower |
numeric The cutoff for down-regulated genes. If not specified, it takes the bottom 10% of the |
upper |
numeric The cutoff for up-regulated genes. If not specified, it takes the top 10% of the dataset |
useFDR |
logical Whether to filter by adjusted p-value |
This function takes in a BPNList object and returns a BPNList object with the enrichr slot updated with process EnrichR Results.
An object of class BPNList with its enrichr slot populated with the results
TRUE
TRUE
This function takes a BPNList object and performs a Geneset Enrichment Analysis and returns a BPNList object with the results of the GSEA
do_gsea_pod( bpn, species = "hsapiens", gmtfile = NULL, lower = NULL, upper = NULL, alpha = 0.05, minSize = 15, maxSize = 500, rankWithSignificance = FALSE, useFDR = TRUE )
do_gsea_pod( bpn, species = "hsapiens", gmtfile = NULL, lower = NULL, upper = NULL, alpha = 0.05, minSize = 15, maxSize = 500, rankWithSignificance = FALSE, useFDR = TRUE )
bpn |
BPNList An object of class BPNList created from prepare_data |
species |
character One of the species for which we provide current GMT pathways. Currently the valid species are hsapiens, mmusculus and rnorvegicus. Cannot be specified along with gmtfile |
gmtfile |
character A full path to a GMT File you would like to use. Cannot be specified along with species |
lower |
numeric The cutoff for down-regulated genes. If not specified, it takes the bottom 10% of the dataset |
upper |
numeric The cutoff for up-regulated genes. If not specified, it takes the top 10% of the dataset |
alpha |
numeric The Alpha value for statistical significance. Defaults to 0.05. |
minSize |
numeric The minimum number of genes that should be in a pathway for it to be included in the analysis |
maxSize |
numeric The maximum number of genes that should be in a pathway for it to be included in the analysis |
rankWithSignificance |
logical Whether to rank genes using p-values |
useFDR |
logical Whether to filter by adjusted p-value |
This function takes a BPNList object and performs a Geneset Enrichment Analysis and returns a BPNList object with the results of the GSEA
An object of class BPNList with its gsea slot populated with the results
TRUE
TRUE
This method takes in a bpn object and performs a leading edge analysis to identify the genes that are driving the majority of pathways.
do_leading_pod(bpn)
do_leading_pod(bpn)
bpn |
An object of class BPNList. Must have the gsea analysis completed beforehand. |
An object of class BPNList with its leading slot populated with the results
TRUE
TRUE
Construct an EnrichRResult object
EnrichRResult( up_results, down_results, upreg, downreg, alpha, upper, lower, dbs, useFDR )
EnrichRResult( up_results, down_results, upreg, downreg, alpha, upper, lower, dbs, useFDR )
up_results |
tbl_df A tibble of enrichment results from the upregulated genes |
down_results |
tbl_df A tibble of enrichment results from the upregulated genes |
upreg |
tbl_df A tibble of up-regulated genes |
downreg |
tbl_df A tibble of down-regulated genes |
alpha |
numeric Alpha level of significance |
upper |
numeric Upper threshold for up-regulated genes |
lower |
numeric Lower threshold for down-regulated genes |
dbs |
character a vector of the databases used for the enrichment analysis |
useFDR |
logical Whether to filter by adjusted p-value |
an object of class EnrichRResult
TRUE
TRUE
This class stores the input parameters and results of the Gene Set Enrichment Analysis.
an object of class EnrichRResult
alpha
numeric. The Alpha threshold for significance
threshold_up
numeric. The logfc threshold for up-regulated genes
threshold_down
numeric. The logfc threshold for down-regulated genes
upregulated_genes
tbl_df. The up-regulated genes from the input DEG tibble
downregulated_genes
tbl_df. The down-regulated genes from the input DEG tibble
dbs_used
character. A vector of the databases used from enrichR
up_enrichr
tbl_df. Enriched pathways in up-regulated genes
down_enrichr
tbl_df. Enriched pathways in down-regulated genes
sig_up_enrichr
tbl_df. Significant enriched pathways in up-regulated genes
sig_down_enrichr
tbl_df. Significant enriched pathways in down-regulated genes
num_upreg
numeric. Number of up-regulated genes
num_downreg
numeric. Number of down-regulated genes
num_up_enrichr
numeric. Number of enriched pathways in up-regulated genes
num_down_enrichr
numeric. Number of enriched pathways in down-regulated genes
num_sig_up_enrichr
numeric. Number of significant enriched pathways in up-regulated genes
num_sig_down_enrichr
numeric. Number of significant enriched pathways in down-regulated genes
empty
logical. A simple check for whether or not the object is empty
TRUE
TRUE
Perform Revigo enrichment analysis
get_revigo_output(input_data)
get_revigo_output(input_data)
input_data |
A dataframe containing GO IDs and associated p-values |
A dataframe containing the Revigo Enrichment analysis
TRUE
TRUE
Construct a GSEAResult Object
GSEAResult(results, pathways, lower, upper, alpha, upreg, downreg, useFDR)
GSEAResult(results, pathways, lower, upper, alpha, upreg, downreg, useFDR)
results |
tbl_df A tibble with the results from fgsea |
pathways |
list A list of vectors with gene sets |
lower |
numeric Lower threshold for down-regulated genes |
upper |
numeric Upper threshold for up-regulated genes |
alpha |
numeric Alpha level of significance |
upreg |
tbl_df A tibble of up-regulated genes |
downreg |
tbl_df A tibble of down-regulated genes |
useFDR |
logical Whether to filter by adjusted p-value |
an object of class GSEAResult
TRUE
TRUE
This class stores the input parameters and results of the Gene Set Enrichment Analysis.
an object of class GSEAResult
alpha
numeric. The Alpha threshold for significance
threshold_up
numeric. The logfc threshold for up-regulated genes
threshold_down
numeric. The logfc threshold for down-regulated genes
upregulated_genes
tbl_df. The up-regulated genes from the input DEG tibble
pathways
tbl_df. The pathways we used, either built-in or user-supplied
downregulated_genes
tbl_df. The down-regulated genes from the input DEG tibble
pos_enriched
tbl_df. The positively enriched pathways
neg_enriched
tbl_df. The negatively enriched pathways
sig_pos_enriched
tbl_df. Significant positively enriched pathways
sig_neg_enriched
tbl_df. Significant positively enriched pathways
num_upreg
numeric. Number of up-regulated genes
num_downreg
numeric. Number of down-regulated genes
num_tested
numeric. Number of pathways tested
num_pos_enriched
numeric. Number of positively enriched pathways
num_neg_enriched
numeric. Number of negatively enriched pathways
num_sig_pos_enriched
numeric. Number of significant positively enriched pathways
num_sig_neg_enriched
numeric. Number of significant negatively enriched pathways
empty
logical. A simple check for whether or not the object is empty
TRUE
TRUE
The processed form of the October 2020 Pathway annotation containing every pathway annotated with the associated genes in humans. This uses the Symbol annotation from BaderLab.
hsapiens
hsapiens
A list
This class stores the result of the results from iLINCS
an object of class iLINCSResult
threshold_up
numeric. LFC threshold for up-regulated genes
threshold_down
numeric. LFC threshold for down-regulated genes
threshold_pval
numeric. P Value threshold for genes.
threshold_similarity
numeric. Similarity threshold
l1000_subset
tbl_df. Subset of L1000 genes in the dataset
upregulated_genes
tbl_df. L1000 genes up-regulatedd in dataset
downregulated_genes
tbl_df. L1000 genes down-regulated in dataset
ilincs_query_signature
tbl_df. Complete iLINCS Query signature
all_perturbagens
tbl_df. Complete list returned from iLINCS of perturbagens
filtered_perturbagens
tbl_df. Filtered list of perturbagens by the similarity threshold
num_genes_l1000
numeric. Number of L1000 genes in dataset
num_genes_upregulated
numeric. Number of up-regulated L1000 genes in dataset
num_genes_downregulated
numeric. Number of down-regulated L1000 genes in dataset
num_all_perturbagens
numeric. Number of all perturbagens returned by iLINCS
num_filtered_perturbagens
numeric. Number of filtered perturbagens returned by iLINCS
empty
logical. A simple check for whether or not the object is empty
TRUE
TRUE
IntegratedResult-class: Class containing Integrated results
and object of class IntegratedResults
placeholder
numeric.
empty
logical. A simple check for whether or not the object is empty
TRUE
TRUE
Extract Leading Edge Genes from GSEA Results
leading_edge(gsea, direction)
leading_edge(gsea, direction)
gsea |
an object of class GSEAResult |
direction |
one of "up" or "down" |
A tibble with the leading edge genes and associated pathways
TRUE
TRUE
Construct an LEResult object
LEResult(leading_up, leading_down)
LEResult(leading_up, leading_down)
leading_up |
tbl_df. A dataframe with the results of all the leading edge genes from upregulated genes |
leading_down |
tbl_df. A dataframe with the results of all the leading edge genes from downregulated genes |
An object of class LEResult
TRUE
TRUE
LEResult-class: Class containing Leading Edge Analysis results
an object of class LEResult
leading_up
tbl_df. A tibble with the results of LE analysis for the upregulated pathways
leading_down
tbl_df. A tibble with the results of LE analysis for the downregulated pathways
count_leading_up
tbl_df. A tibble with the counts of LE genes for the upregulated pathways
count_leading_down
tbl_df. A tibble with the counts of LE genes for the downregulated pathways
num_leading_up
numeric. Number of LE genes for the upregulated pathways
num_leading_down
numeric. Number of LE genes for the downregulated pathways
empty
logical. A simple check for whether or not the object is empty
TRUE
TRUE
Load Pathways data
load_pathways(species)
load_pathways(species)
species |
The species. Can be hsapiens, mmusculus or rnorvegicus |
The loaded pathways
importFrom utils data
TRUE
TRUE
The processed form of the October 2020 Pathway annotation containing every pathway annotated with the associated genes in mice. This uses the Symbol annotation from BaderLab.
mmusculus
mmusculus
A list
This function takes vectors of gene names, log Fold-change values and optionally p-values and formats them into a tibble for downstream analysis.
prepare_data(genes, logfc, pvalues = NULL)
prepare_data(genes, logfc, pvalues = NULL)
genes |
a character vector of gene names |
logfc |
a numeric vector of log fold-change values |
pvalues |
(optional) a numeric vector of p-values |
The function returns an object of class BPNList that will update as the analysis proceeds
An object of class BPNList with the following slot set:
input
TRUE
TRUE
RevigoResult-class: Class containing results from Revigo
and object of class RevigoResult
placeholder
numeric.
empty
logical. A simple check for whether or not the object is empty
TRUE
TRUE
The processed form of the October 2020 Pathway annotation containing every pathway annotated with the associated genes in rats. This uses the Symbol annotation from BaderLab.
rnorvegicus
rnorvegicus
A list