Skip to contents

Identify Top Genes and Values of Communities

Usage

display_top_genes(
  membership_matrix,
  K = 10,
  output = c("both", "genes", "values")
)

Arguments

membership_matrix

a community membership (kME) matrix with genes as rows and communities as columns. Often community_membership or full_community_membership output from icwgcna()

K

number of genes to find.

output

Should output show both top genes and values, genes only, or values only

Value

K x Communities data.frame of top genes and ranks (if output = "genes")

K x Communities data.frame of top values and ranks (if output = "values")

Long data.frame with columns Community, Gene, Value, Rank (if output = "both")

Examples

if (FALSE) { # \dontrun{
library("UCSCXenaTools")
luad <- getTCGAdata(
  project = "LUAD", mRNASeq = TRUE, mRNASeqType = "normalized",
  clinical = FALSE, download = TRUE
)
ex <- as.matrix(data.table::fread(luad$destfiles), rownames = 1)
results <- icwgcna(ex)

top_genes <- display_top_genes(
    results$community_membership,
    K = 100,
    output = "both")
} # }