The process of SCENIC

Last week we learned Transcription factor motif finding, also, recently I was using SCENIC to find out some key TFs which are responsible for the generations and functions of tumor associated neutrophils (TAN). So in this mini-review, I want to introduce how SCENIC find out the key transcription factors aertslab/SCENIC: vignettes/detailedStep_1_coexNetwork2modules.Rmd (rdrr.io).

SCENIC (Single Cell rEgulatory Network Inference and Clustering) is a tool to infer Gene Regulatory Networks and their associated TFs from single-cell RNA-seq data. SCENIC was developed by aertslab (1), and depended on three tools which also developed by them: GENIE3, RcisTarget, AUCell. In this review I will focus on the first two tools.

1. GENIE3 (GEne Network Inference with Ensemble of trees) (2)

The aim of this tools is to give rise to the genetic regulatory networks (GRNs) using expression matrix. To achieve this destination, GENIE3 solve n regression problems: every target’s expression pattern will be predicted using all regulators’ expression patterns (In default, we consider one gene as a target, and all the other genes are its regulator. GENIE3 allow you to define specifical regulators instead of using all genes). The solvation of each regression problem will be relied on the tree-based ensemble methods Random Forests or Extra-Trees. Finally, the function “GENIE3” will return a matrix, with its row are targets, columns are regulaters (weightMat <- GENIE3(exprMatr, regulators=regulators)), every cell [i,j] is the weight of the regulation of i on j (wij).

The default method is random forest (3). Random forest functions as an ensemble of individual decision trees (the number of trees can be set using nTrees). Every tress is based on K genes (can be set using K) which is randomly selected from all the genes except target genes (all the regulators). Throughout the iterative process, each run results in the derivation of a regulatory network for a single specific target (4). The process repeats until a comprehensive network is generated for all individual targets. Therefore, the output is a compendium of individual regulatory networks for all the target genes (Figure1).

Here I will give a simple example how a single tree is constructed (Figure 2):

  1. We randomly select k regulators. The corresponding target’s’ expression denoted as S.

  2. We calculate the variance of S: Var(S)

  3. We select a split node to separate S into two sets: St and Sf, we calculate their variance: Var(St), Var(Sf). St and Sf own #St and #Sf percent of S.

  4. The Importance I of this split will be calculated as:

I(N) = \#SVar(S) - \#S_tVar(S_t) - \#S_fVar(S_f)

  1. We chose the maximum of I(N) as current node and split.

  2. For the newly generated St and Sf, consider it as new S, repeat step 2-5

  3. Recursively …

The importance of 'reg1' (a regulator gene) to the target within each tree is measured by its contribution to the total importance.

After iterating across multiple trees, we aggregate these measures of importance to form an average value. To ease interpretation, this final average importance score is then normalized to reside within a range from 0 to 1. These normalized values represent the weights in the final output, providing an intuitive measure of the significance of each regulator gene in relation to the target.

SCENIC only care about TFs regulatory effect on other genes, so SCENIC will use TFs as regulators instead of all genes in default. After calculating the TFs’ regulatory network, SCENIC will create TF-modules to select the best targets for each TF:

a. Targets with weight > 0.001

b. Targets with weight > 0.005

c. Top 50 targets (targets with highest weight)

d. Targets for which the TF is within its top 5 regulators

e. Targets for which the TF is within its top 10 regulators

f. Targets for which the TF is within its top 50 regulators

Then, the GENIE3’s job was done, we got each TF’s best targets.


Figure 1

Figure 2

2. RcisTarget

RcisTarget functions to identify transcription factor (TF) binding motifs that are over-represented within a specified gene list. In the context of SCENIC, we already procure TF-modules for each transcription factor. Each individually obtained module is treated as a gene list and is assessed to determine whether its identified TF binding motifs match previous TF via GENIE3. Importantly, if a match is identified, this gene list (or module) is deemed a highly reliable TF regulatory network. This network is then utilized to estimate its activity within each single cell.

The calculations in RcisTarget are primarily based on the data from 'hg19-500bp-upstream-7species.mc9nr.feather' resource file. You can consider this as a matrix. The rows of the matrix are representative of different motifs, and the columns denote individual genes. Each element within the matrix [i,j] signifies the rank of the intensity of a motifi for genej's 500-bp upstream region. Essentially, this value represents the regulatory intensity of a particular motifi on genej. This matrix is look like as blow:

feather data

Also, we need the association between motifs and TFs, as below:
TFs data

The calculation is as follow:

  1. For every motif, we arrange all genes (or selected some genes, default top 5000 genes) on the x-axis in ascending order based on their rank value;

  2. Then, we draw a step line graph and calculate the area under this line. The resulting value, expressed as a proportion of the total rectangle (from x=0 to x=total genes, y=0 to max rank), forms the Enrichment Score (ES);

  3. After computing the ES for all motifs, we then calculate a Normalized Enrichment Score (NES):
    NES_i = \frac{ES_i - mean(ES)} {variance(ES)}

In the end, motifs which have a NES greater than 3 are considered significantly enriched.

Based on the correlation between the motifs and transcription factors (TFs), we can infer whether the gene list is regulated by the TFs.


Figure 3

Therefore, we can perform this enrichment analysis for every TF-module of each TF, and confirm its regulatory effect on this gene set. Once we identify the highly credible TF-modules, we can use tools like AUCell to evaluate their activity in each individual cell.

Reference

  1. Aibar S, González-Blas CB, Moerman T, Huynh-Thu VA, Imrichova H, Hulselmans G, et al. SCENIC: single-cell regulatory network inference and clustering. Nature methods. 2017;14(11):1083-6.
  2. Huynh-Thu VA, Irrthum A, Wehenkel L, Geurts P. Inferring Regulatory Networks from Expression Data Using Tree-Based Methods. PLOS ONE. 2010;5(9):e12776.
  3. Geurts P, Irrthum A, Wehenkel L. Supervised learning with decision tree-based methods in computational and systems biology. Molecular BioSystems. 2009;5(12):1593-605.
  4. Breiman L, Friedman JH, Olshen RA, Stone CJ, editors. Classification and Regression Trees1984.
©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 219,869评论 6 508
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 93,716评论 3 396
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 166,223评论 0 357
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 59,047评论 1 295
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 68,089评论 6 395
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 51,839评论 1 308
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 40,516评论 3 420
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 39,410评论 0 276
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 45,920评论 1 319
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 38,052评论 3 340
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 40,179评论 1 352
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 35,868评论 5 346
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 41,522评论 3 331
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 32,070评论 0 22
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 33,186评论 1 272
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 48,487评论 3 375
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 45,162评论 2 356

推荐阅读更多精彩内容