Topic_func_anno: Annotating each topic's function.

View source: R/MUSIC.r

Topic_func_annoR Documentation

Annotating each topic's function.

Description

After calculating topics, MUSIC obtains the occurring probabilities of genes available in each topic. For each topic, genes with large probabilities were used to annotate the topic’s function. Specifically, MASCOT firstly selects the n% top-ranked (default 20%) genes of each topic based on their occurring probabilities. Then these genes were used to perform the functional enrichment annotation with R package clusterProfiler together with a FDR correction. Finally the top-ranked n (default 3) GO terms were selected to represent each topic’s key functions.

Usage

Topic_func_anno(model, species = "Hs", topNum = 5, plot = TRUE, plot_path = "./topic_annotation_GO.pdf")

Arguments

model

Object of class "LDA" with the optimal topic number.

species

The species the cells belong to. Currently species="Hs" for homo sapiens or species="Mm" for mus musculus are available.

topNum

The top-ranked number (default 5) GO terms were selected to represent each topic’s key functions.

plot

TRUE by default. If TRUE, plot the graph.

plot_path

The save path of the graph you plot. It works only when the parameter "plot" is TRUE.

Value

A list contains a dataframe showing the annotation result and the gene symbol to annotate the function of each topic.

Author(s)

Bin Duan

References

Yu G, Wang LG, Han Y, He Q. Y. clusterProfiler: an R package for comparing biological themes among gene clusters. Omics. 2012;16:284–287. doi: 10.1089/omi.2011.0118.


bm2-lab/MASCOT documentation built on April 19, 2024, 4:35 p.m.