10X單細胞(10X空間轉錄組)細胞通訊分析聯合大全

作者,追風少年i

周四了,一周最好的時光,不知道大家感覺怎么樣了?2022年上半年的最后一天,時光總是匆匆,不會為自己停留片刻。白哥有一句臺詞,之前做的再好也回不去了,項目交出去的那一刻,便不再屬于自己,那如果新的項目做不成,就該考慮換個工作了~~~~你再有輝煌也都是過去的事情了,要是因為過去的事出不來的話,我們就會越來越平庸。

半年了,我們要做總結,希望大家都能在自己擅長的領域有所成就~~~

圖片.png

七種方法的整合

show_methods()
#>  [1] "connectome"      "logfc"           "natmi"           "sca"            
#>  [5] "cellphonedb"     "cytotalk"        "call_squidpy"    "call_cellchat"  
#>  [9] "call_connectome" "call_sca"        "call_italk"      "call_natmi"

其中重點涉及

10X單細胞之細胞通訊篇章-----Connectome
10X單細胞(10X空間轉錄組)通訊分析之CellChat
考慮空間位置的通訊分析手段---CellphoneDB(V3.0)
10X單細胞(10X空間轉錄組)通訊分析之CytoTalk(從頭構建信號轉導網絡 )
10X單細胞空間聯合分析回顧之squidpy
10X單細胞(10X空間轉錄組)細胞通訊的一個小小的細節
單細胞數據細胞通訊分析軟件NATMI
10X單細胞(10X空間轉錄組)通訊分析之NicheNet
數據庫包括
# Resource currently included in OmniPathR (and hence `liana`) include:
show_resources()
#>  [1] "Default"          "Consensus"        "Baccin2019"       "CellCall"        
#>  [5] "CellChatDB"       "Cellinker"        "CellPhoneDB"      "CellTalkDB"      
#>  [9] "connectomeDB2020" "EMBRACE"          "Guide2Pharma"     "HPMR"            
#> [13] "ICELLNET"         "iTALK"            "Kirouac2010"      "LRdb"            
#> [17] "Ramilowski2015"   "OmniPath"

當然,我們要進一步擴充,首先來看LIANA與NicheNet的聯合分析

LIANA(LIgand-receptor AAnalysis frAmework)是一個框架,能夠使用不同的資源和方法對來自單細胞轉錄組學的配體-受體相互作用進行優先排序。 它允許用戶系統地生成關于來自給定細胞類型的哪些配體與另一種細胞類型的受體結合的假設。 與 LIANA 相比,NicheNet 旨在深化將配體與一組轉錄靶標連接起來的細胞內機制,從而廣泛使用來自多個來源的先驗知識。 LIANA 和 NicheNet 并不相互排斥,但在某些情況下可能相當互補,因為它們旨在探索細胞間和細胞內通信的不同方面。

圖片.png

其中Nichenet的參考鏈接在NicheNet,值得大家深入學習。

圖片.png
library(tidyverse)
library(liana)
library(nichenetr)
library(Seurat)
library(ggrepel)
library(cowplot)
options(timeout=300)

加載數據

# single-cell expression matrix described in Puram et al. 2017
hnscc_expression <- readRDS(url("https://zenodo.org/record/3260758/files/hnscc_expression.rds"))
# model weights
ligand_target_matrix <- readRDS(url("https://zenodo.org/record/3260758/files/ligand_target_matrix.rds"))

感興趣的細胞進行下游分析

expression <- hnscc_expression$expression
sample_info <- hnscc_expression$sample_info
colnames(sample_info) <- make.names(colnames(sample_info))

# filter samples based on vignette's information and add cell type
tumors_remove <-  c("HN10", "HN", "HN12", "HN13", "HN24", "HN7", "HN8", "HN23")
sample_info <- sample_info %>%
  subset( !(tumor %in% tumors_remove) & Lymph.node == 0) %>%
  # fix some cell type identity names
  mutate(cell_type = ifelse(classified..as.cancer.cell == 1, "Tumor", non.cancer.cell.type)) %>%
  subset(cell_type %in% c("Tumor", "CAF"))

# cell ID as rownames
rownames(sample_info) <- sample_info$cell

# subset expression to selected cells
expression <- expression[sample_info$cell, ]

# gene set of interest
geneset_oi <- read_tsv(url("https://zenodo.org/record/3260758/files/pemt_signature.txt"), col_types = cols(), col_names = "gene") %>%
  pull(gene) %>%
  .[. %in% rownames(ligand_target_matrix)]

Run LIANA

# create seurat object
seurat_object <- Seurat::CreateAssayObject(counts = expm1(t(expression))) %>%
  Seurat::CreateSeuratObject(., meta.data = sample_info) %>%
  Seurat::NormalizeData()

# set cell identity to cell type
Idents(seurat_object) <- seurat_object@meta.data$cell_type

liana_results <- liana_wrap(seurat_object) %>%
  liana_aggregate()

By default, LIANA will score the ligand-receptor interactions in all the possible directions within the two cell types of interest. This includes: Autocrine signaling (e.g. CAFs -> CAFs), CAFs -> Tumor cells and Tumor cells -> CAFs. As we are only interested in the CAFs -> Tumor cell direction, we filter the results and visualize the top 50 interactions according to the consensus/aggregate rank across methods. The aggregate rank itself can be interpreted as the significance of preferential enrichment for the interactions.

# filter results to cell types of interest
caf_tumor_results <- liana_results %>%
  subset(source == "CAF" & target == "Tumor") %>%
  dplyr::rename(ligand=ligand.complex, receptor=receptor.complex)

# filter results to top N interactions
n <- 50
top_n_caf_tumor <- caf_tumor_results %>%
  arrange(aggregate_rank) %>%
  slice_head(n = n) %>%
  mutate(id = fct_inorder(paste0(ligand, " -> ", receptor)))

# visualize median rank
top_n_caf_tumor %>%
  ggplot(aes(y = aggregate_rank, x = id)) +
  geom_bar(stat = "identity") +
  xlab("Interaction") + ylab("LIANA's aggregate rank") +
  theme_cowplot() +
  theme(axis.text.x = element_text(size = 8, angle = 60, hjust = 1, vjust = 1))
圖片.png

Run NicheNet using LIANA’s ligands

將 LIANA 與 NicheNet 結合的關鍵方面是可以使用 LIANA 優先考慮的配體作為 NicheNet 的潛在配體集。 不會評估受體也在受體細胞類型中表達的所有表達配體,我們將僅探索那些被 LIANA 中包含的方法優先考慮的配體。 因此,選擇形成前面所示相互作用的配體。

# get ligands and filter to those included in NicheNet's ligand-target matrix
ligands <- unique(top_n_caf_tumor$ligand)
ligands <- ligands[ligands %in% colnames(ligand_target_matrix)]

background_genes <- expression[sample_info$cell[sample_info$cell_type == "Tumor"], ] %>%
  apply(2,function(x){10*(2**x - 1)}) %>%
  apply(2,function(x){log2(mean(x) + 1)}) %>%
  .[. >= 4] %>%
  names()

并使用前面提到的 pEMT 基因集執行 NicheNet 預測配體活動

nichenet_activities <- predict_ligand_activities(
  geneset = geneset_oi,
  background_expressed_genes = background_genes,
  ligand_target_matrix = ligand_target_matrix, potential_ligands = ligands
)

可視化

# prepare data for visualization
vis_liana_nichenet <- top_n_caf_tumor %>%
  inner_join(nichenet_activities, by = c("ligand" = "test_ligand")) %>%
  arrange(pearson) %>%
  mutate(ligand = fct_inorder(ligand))

# prepare NicheNet figure
nichenet_scores_plot <- vis_liana_nichenet %>%
  group_by(ligand) %>%
  summarize(pearson = mean(pearson)) %>%
  ggplot(aes(y = ligand, x = pearson)) +
  geom_bar(stat = "identity") +
  ggtitle("NicheNet") +
  xlab("Pearson's score") +
  theme_cowplot() +
  theme(axis.text.y = element_blank(),
        axis.ticks.y = element_blank(),
        axis.title.y = element_blank(),
        axis.line.y = element_line(color = "white"),
        plot.title = element_text(hjust = 0.5),
        axis.text.x = element_text(angle = 60, hjust = 1, vjust = 1))

# prepare LIANA figure
liana_receptor_heatmap <- vis_liana_nichenet %>%
  ggplot(aes(y = ligand, x = receptor, fill = aggregate_rank)) +
  geom_tile() +
  theme_cowplot() +
  ggtitle("LIANA") +
  ylab("Ligand") + xlab("Receptor") +
  theme(axis.text.x = element_text(angle = 60, hjust = 1, vjust = 1),
        plot.title = element_text(hjust = 0.5),
        panel.grid.major = element_line(colour = "gray", linetype = 2),
        legend.position = "left")

# combine plots
plot_grid(liana_receptor_heatmap, nichenet_scores_plot,
          align = "h", nrow = 1, rel_widths = c(0.8,0.3))
圖片.png

其實,做單細胞通訊的軟件非常多,我都放在下面,供大家參考,包括空間轉錄組做通訊的分析方法

10X空間轉錄組之構建鄰域通訊網絡

10X空間轉錄組之組織區域臨近通訊實現方法

10X單細胞(10X空間轉錄組)細胞通訊分析之InterCellDB(推斷通訊中感興趣的生物學功能)

10X單細胞(10X空間轉錄組)數據分析之基于代謝物介導的細胞間通訊

10X空間轉錄組之空間臨近通訊分析stlearn進階版

10X單細胞(10X空間轉錄組)之單細胞精度分析細胞通訊

10X單細胞(10X空間轉錄組)通訊分析之匯總(scSeqComm)

10X空間轉錄組----空間臨近通訊的實現方法

10X空間轉錄組數據分析之空間臨近通訊網絡(DAGBagST)

10X空間轉錄組之再談距離分析和空間臨近通訊

10X空間轉錄組的位點注釋和臨近通訊

10X單細胞(10X空間轉錄組)之配受體聯合TF因子的通訊分析(cellcall)

10X單細胞(10X空間轉錄組)利用軌跡分析推斷細胞間的實時通訊(TraSig)

10X單細胞(10X空間轉錄組)細胞通訊之組間通訊差異分析(scDiffCom)

10X單細胞(10X空間轉錄組)多種通訊軟件聯合分析之liana

10X單細胞(10X空間轉錄組)之細胞通訊軟件之間的分析比較

10X單細胞(10X空間轉錄組)空間相關性分析和cellphoneDB與NicheNet聯合進行細胞通訊分析

10X空間轉錄組細胞通訊之stlearn(尋找區域交流熱點中心)

10X空間轉錄組(10X單細胞)之論細胞通訊空間分布的重要性

10X單細胞(10X空間轉錄組)通訊分析CellChat之多樣本通訊差異分析

10X單細胞通訊分析之scMLnet(配受體與TF,差異基因(靶基因)網絡通訊分析)

10X單細胞通訊分析之CrosstalkR(特異性和通訊強度的變化都很重要)

10X單細胞通訊分析之ICELLNET

10X空間轉錄組通訊分析章節3

空間通訊分析章節2

10X空間轉錄組做細胞通訊的打開方式

細胞通訊軟件RNAMagnet

好了,已經分享給大家了,生活很好,有你更好,百度文庫出現了大量抄襲我的文章,對此我深表無奈,我寫的文章,別人掛上去賺錢,抄襲可恥,掛到百度文庫的人更可恥

?著作權歸作者所有,轉載或內容合作請聯系作者
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發布,文章內容僅代表作者本人觀點,簡書系信息發布平臺,僅提供信息存儲服務。
禁止轉載,如需轉載請通過簡信或評論聯系作者。
  • 序言:七十年代末,一起剝皮案震驚了整個濱河市,隨后出現的幾起案子,更是在濱河造成了極大的恐慌,老刑警劉巖,帶你破解...
    沈念sama閱讀 228,702評論 6 534
  • 序言:濱河連續發生了三起死亡事件,死亡現場離奇詭異,居然都是意外死亡,警方通過查閱死者的電腦和手機,發現死者居然都...
    沈念sama閱讀 98,615評論 3 419
  • 文/潘曉璐 我一進店門,熙熙樓的掌柜王于貴愁眉苦臉地迎上來,“玉大人,你說我怎么就攤上這事?!?“怎么了?”我有些...
    開封第一講書人閱讀 176,606評論 0 376
  • 文/不壞的土叔 我叫張陵,是天一觀的道長。 經常有香客問我,道長,這世上最難降的妖魔是什么? 我笑而不...
    開封第一講書人閱讀 63,044評論 1 314
  • 正文 為了忘掉前任,我火速辦了婚禮,結果婚禮上,老公的妹妹穿的比我還像新娘。我一直安慰自己,他們只是感情好,可當我...
    茶點故事閱讀 71,826評論 6 410
  • 文/花漫 我一把揭開白布。 她就那樣靜靜地躺著,像睡著了一般。 火紅的嫁衣襯著肌膚如雪。 梳的紋絲不亂的頭發上,一...
    開封第一講書人閱讀 55,227評論 1 324
  • 那天,我揣著相機與錄音,去河邊找鬼。 笑死,一個胖子當著我的面吹牛,可吹牛的內容都是我干的。 我是一名探鬼主播,決...
    沈念sama閱讀 43,307評論 3 442
  • 文/蒼蘭香墨 我猛地睜開眼,長吁一口氣:“原來是場噩夢啊……” “哼!你這毒婦竟也來了?” 一聲冷哼從身側響起,我...
    開封第一講書人閱讀 42,447評論 0 289
  • 序言:老撾萬榮一對情侶失蹤,失蹤者是張志新(化名)和其女友劉穎,沒想到半個月后,有當地人在樹林里發現了一具尸體,經...
    沈念sama閱讀 48,992評論 1 335
  • 正文 獨居荒郊野嶺守林人離奇死亡,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內容為張勛視角 年9月15日...
    茶點故事閱讀 40,807評論 3 355
  • 正文 我和宋清朗相戀三年,在試婚紗的時候發現自己被綠了。 大學時的朋友給我發了我未婚夫和他白月光在一起吃飯的照片。...
    茶點故事閱讀 43,001評論 1 370
  • 序言:一個原本活蹦亂跳的男人離奇死亡,死狀恐怖,靈堂內的尸體忽然破棺而出,到底是詐尸還是另有隱情,我是刑警寧澤,帶...
    沈念sama閱讀 38,550評論 5 361
  • 正文 年R本政府宣布,位于F島的核電站,受9級特大地震影響,放射性物質發生泄漏。R本人自食惡果不足惜,卻給世界環境...
    茶點故事閱讀 44,243評論 3 347
  • 文/蒙蒙 一、第九天 我趴在偏房一處隱蔽的房頂上張望。 院中可真熱鬧,春花似錦、人聲如沸。這莊子的主人今日做“春日...
    開封第一講書人閱讀 34,667評論 0 26
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽。三九已至,卻和暖如春,著一層夾襖步出監牢的瞬間,已是汗流浹背。 一陣腳步聲響...
    開封第一講書人閱讀 35,930評論 1 287
  • 我被黑心中介騙來泰國打工, 沒想到剛下飛機就差點兒被人妖公主榨干…… 1. 我叫王不留,地道東北人。 一個月前我還...
    沈念sama閱讀 51,709評論 3 393
  • 正文 我出身青樓,卻偏偏與公主長得像,于是被迫代替她去往敵國和親。 傳聞我的和親對象是個殘疾皇子,可洞房花燭夜當晚...
    茶點故事閱讀 47,996評論 2 374

推薦閱讀更多精彩內容