theSpecies: Human, mouse, or a character that is compatible with g:ProfileR.
scMappR_vals: cell weighted Fold-changes of differentially expressed genes.
background_genes: A list of background genes to test against. NULL assumes all genes in g:profileR gene set databases.
output_directory: Path to the directory where files will be saved.
plot_names: Names of output.
number_genes: Number of genes to if there are many, many DEGs.
newGprofiler: Whether to use g:ProfileR or gprofiler2 (T/F).
toSave: Allow scMappR to write files in the current directory (T/F).
path: If toSave == TRUE, path to the directory where files will be saved.
Returns
List with the following elements: - rank_increase: A list containing the degree of rank change between bulk DE genes and cwFold-changes. Pathway enrichment and TF enrichment of these reranked genes.
non_rank_increase: list of DFs containing the pathway and TF enrichment of cwFold-changes.
Details
This function re-ranks cwFoldChanges based on their absolute cell-type specificity scores (per-celltype) as well as their rank increase in cell-type specificity before completing an ordered pathway analysis. In the second method, only genes with a rank increase in cell-type specificity were included.