generes_to_heatmap function

Generate signature matrix

Generate signature matrix

Convert a list of cell-type markers from FindMarkers in Seurat to a signature matrix defined by odds ratio and rank.

generes_to_heatmap( generes = generes, species = "human", naming_preference = -9, rda_path = "", make_names = TRUE, internal = FALSE )

Arguments

  • generes: A list of cell-type markers with fold-changes and p-values (FindMarkers output in Seurat).
  • species: The species of gene symbols, if not internal, "human" or "mouse".
  • naming_preference: Likely cell-types given tissues (to be passed into human_mouse_ct_marker_enrich).
  • rda_path: Path to output direcotry, if toSave is true.
  • make_names: Identify names of cell-type markers using the Fisher's exact test method (T/F).
  • internal: If this function is pre-processing from Panglao (T/F).

Returns

List with the following elements: - pVal: A dataframe containing the signature matrix of ranks (-log10(Padj) * sign(fold-change)).

  • OR: A dataframe containing the signature matrix of odds ratios.

  • cellname: A vector of the cell-labels returned from the GSVA method.

  • topGenes: the top 30 mos expressed genes in each cell-type.

Details

Take a list of compiled differentially expressed genes from different cell-types, identify what the cell-types are using the Fisher's exact test, and then convert into a signature matrix for both the adjusted p-value and odds ratio.

Examples

data(POA_example) POA_generes <- POA_example$POA_generes signature <- generes_to_heatmap(POA_generes,species = -9, make_names = FALSE)
  • Maintainer: Dustin Sokolowski
  • License: GPL-3
  • Last published: 2023-06-30