Case study: SIRPA xQTL and AD GWAS¶

This notebook documents the analysis of xQTL case study on a targeted gene, SIRPA.

  • Section 0: Sanity check
  • Section 1: Fine-mapping for xQTL and GWAS
  • Section 2: Multi-context colocalization with Bellenguez 2022
  • Section 3: Refinement of colocalized loci with other AD GWAS
  • Section 4: Assessment of multi-context xQTL effect sizes
  • Section 5: Multi-context causal TWAS (including conventional TWAS and MR)
  • Section 6: Context specific multi-gene fine-mapping
  • Section 7: Epigenomic QTL and their target regions
  • Section 8: Context focused validation in other xQTL data
  • Section 9: Non-linear effects of xQTL
  • Section 10: in silico functional studies in iPSC model
  • Section 11: Functional annotations of selected loci
  • Section 12: Candidate loci as trans-xQTL

Overview¶

FunGen-xQTL resource contains 67 xQTL contexts as well as 9 AD GWAS fine-mapped genome-wide. The overarching goal for case studies is to use these resource to raise questions and learn more about gene targets of interest.

Overall, a case study consists of the following aspects:

  • Check the basic information of the gene
  • Check the existing xQTL and integrative analysis results, roughly including
    • Summary table for univariate fine-mapping
    • Marginal association results
    • Multi-gene and multi-context fine-mapping
    • Multi-context colocalization with AD GWAS
    • TWAS, MR and causal TWAS
    • Integration with epigenetic QTL
    • Quantile QTL
    • Interaction QTL
    • Validation:
      • Additional xQTL data in FunGen-xQTL
      • Additional AD GWAS data-set already generated by FunGen-xQTL
    • In silico functional studies
      • Additional iPSC data-sets
    • Functional annotations of variants, particularly in relevant cellular contexts
  • Creative thinking: generate hypothesis, search in literature, raise questions to discuss

Computing environment setup¶

Interactive analysis will be done on AWS cloud powered by MemVerge. Please contact Gao Wang to setup accounts for you to start the analysis.

Please follow instructions on https://wanggroup.org/productivity_tips/mmcloud-interactive to configure your computing environment. Here are some additional packages you need to install after the initial configuration, in order to perform these analysis:

in terminal with bash:

micromamba install -n r_libs r-pecotmr

in R:

install.packages('BEDMatrix')

How to Use This Notebook¶

  1. Before you start: Load functions from cb_plot.R and utilis.R, located at <xqtl-paper>/codes/. These functions and resources are packaged to streamline the analysis and ensure everything is as clean as possible. And also the codes for ColocBoost under path /data/colocalization/colocboost/R.
  2. Inside of this notebook, use sed -i or Ctrl+F to replace the gene SIRPA with the gene you want to analyze.
  3. For detailed analysis in some sections, please refer to the corresponding analysis notebooks as indicated. These companion notebooks are available under this same folder. The rest of the tasks can be completed with a few lines of code, as demonstrated in this notebook.
  4. Similarly for the companion notebooks you should also use the sed -i or Ctrl+F replacing gene_name (SIRPA in this case) with the gene you want to investigate.

While using this notebook, you may need to generate three intermediate files from Sections 1 and 2, which will be useful for downstream analysis:

  • a. Section 1:
    • Fine-mapping contexts that indicate shared signals with AD, SIRPA_finemapping_contexts.rds. This can be used as input for Section 8 the multi-cohort validation step
    • A subset of the xQTL-AD table, Fungen_xQTL_allQTL.overlapped.gwas.export.SIRPA.rds. This can be used as input for Section 12.
  • b. Section 2: A variant list showing colocalization in cohorts we analyzed with ColocBoost, SIRPA_colocboost_res.rds. this can be used as input for Sections 7, 9, 10, and 12.

Section 0: Sanity check¶

Check the basic information of the gene¶

  • To gain a preliminary understanding of this gene’s expression—specifically, whether it is cell-specific—can help us quickly determine if our results are consistent with expectations.

Useful websites:

  1. check gene function, (immune) cell type specificity, tissue specifity, protein location: https://www.proteinatlas.org
  2. check gene position and structure: https://www.ncbi.nlm.nih.gov/gene/
  3. other collective information: https://www.genecards.org

Check the existing results which are inputs to this analysis¶

Check the existing results which are inputs to this analysis¶

In [1]:
# If an error occurs while sourcing scripts, it might be because your get() returned NULL. 
#Please restart the kernel or click the R kernel in the upper right corner to resolve the issue.
source('../../codes/cb_plot.R')
source('../../codes/utilis.R')

for(file in list.files("/data/colocalization/colocboost/R", pattern = ".R", full.names = T)){
          source(file)
        }
gene_name = 'SIRPA'

dir.create(paste0('plots/', gene_name), recursive = T)
In [2]:
target_gene_info <- get_gene_info(gene_name = gene_name)
target_gene_info
$gene_info
A data.table: 1 x 14
region_id#chrstartendTSSLD_matrix_idLD_sumstats_idLD_sumstats_id_oldTADB_indexTADB_idgene_startgene_endsliding_windowsgene_name
<chr><chr><dbl><dbl><int><chr><chr><chr><chr><chr><int><int><chr><chr>
ENSG00000198053chr20042000001894166chr20:2517368-4092203,chr20:61521-854451,chr20:854451-2517368,chr20:4092203-585452920_2517368-4092203,20_61521-854451,20_854451-2517368,20_4092203-585452920_2517368-4092203,20_61521_854451,20_854451_2517368,20_4092203_5854529TADB_1266chr20_0_519595318941671940592chr20:0-7123030,chr20:2043621-9019805,chr20:4114953-9968360SIRPA
$target_LD_ids
A matrix: 1 x 4 of type chr
chr20:2517368-4092203chr20:61521-854451chr20:854451-2517368chr20:4092203-5854529
$target_sums_ids
A matrix: 1 x 4 of type chr
20_2517368-409220320_61521-85445120_854451-251736820_4092203-5854529
$gene_region
'chr20:0-4200000'
$target_TAD_ids
A matrix: 1 x 1 of type chr
chr20_0_5195953
In [2]:
target_gene_info <- get_gene_info(gene_name = gene_name)
target_gene_info
$gene_info
A data.table: 1 x 14
region_id#chrstartendTSSLD_matrix_idLD_sumstats_idLD_sumstats_id_oldTADB_indexTADB_idgene_startgene_endsliding_windowsgene_name
<chr><chr><dbl><dbl><int><chr><chr><chr><chr><chr><int><int><chr><chr>
ENSG00000198053chr20042000001894166chr20:2517368-4092203,chr20:61521-854451,chr20:854451-2517368,chr20:4092203-585452920_2517368-4092203,20_61521-854451,20_854451-2517368,20_4092203-585452920_2517368-4092203,20_61521_854451,20_854451_2517368,20_4092203_5854529TADB_1266chr20_0_519595318941671940592chr20:0-7123030,chr20:2043621-9019805,chr20:4114953-9968360SIRPA
$target_LD_ids
A matrix: 1 x 4 of type chr
chr20:2517368-4092203chr20:61521-854451chr20:854451-2517368chr20:4092203-5854529
$target_sums_ids
A matrix: 1 x 4 of type chr
20_2517368-409220320_61521-85445120_854451-251736820_4092203-5854529
$gene_region
'chr20:0-4200000'
$target_TAD_ids
A matrix: 1 x 1 of type chr
chr20_0_5195953
In [3]:
gene_id = target_gene_info$gene_info$region_id
chrom = target_gene_info$gene_info$`#chr`
In [4]:
source('../../codes/utilis.R')
expression_in_rosmap_bulk(target_gene_info)
No description has been provided for this image

Section 1: Fine-mapping for xQTL and GWAS¶

see notebook

In [15]:
region_p
No description has been provided for this image

Bellenguez et al GWAS signals has many overlap with CS from other xQTL sources. This motivates us to look further. The figure above shows the ranges of CS to give us a loci level idea. Below, we show the variants in those CS, color-coding the variants that are shared between them in the same color. In particular, AD GWAS signals are also captured by a few xQTL data, although at this point we don't have formal statistical (colocalization) evidences for these observations yet.

In [17]:
pip_p
No description has been provided for this image

Section 2: Multi-context colocalization with Bellenguez 2022¶

This is done using ColocBoost. The most updated version of ColocBoost results are under path s3://statfungen/ftp_fgc_xqtl/analysis_result/ColocBoost/2024_9/

In [4]:
cb_res <- readRDS(paste0("/data/analysis_result/ColocBoost/2024_9/",gene_id,"_res.rds") )
In [4]:
cb_res <- readRDS(paste0("/data/analysis_result/ColocBoost/2024_9/",gene_id,"_res.rds") )
In [9]:
cb <- plot_cb(cb_res = cb_res, cex.pheno = 1.5, x.phen = -0.2)
No description has been provided for this image
In [10]:
pdf('plots/SIRPA/sec2.colocboost_res.pdf', width = 10, height = 5)
replayPlot(cb$p)
dev.off()
pdf: 2
In [11]:
# colocalized variants
cb_res_table
A data.frame: 1 x 8
colocalized phenotypespurity# variantshighest VCPcolocalized indexcolocalized variantsmax_abs_z_variantcset_id
<chr><dbl><dbl><dbl><chr><chr><chr><chr>
DLPFC; AC; PCC; pQTL; AC_unproductive0.944002990.0860290110483; 10433; 10425; 10441; 10424; 10406; 10407; 10410; 10414; 10434; 10436; 10443; 10444; 10445; 10454; 10457; 10458; 10459; 10460; 10461; 10462; 10479; 10432; 10394; 10395; 10413; 10449; 10396; 10397; 10487; 10488; 10408; 10409; 10455; 10456; 10415; 10416; 10480; 10452; 10453; 10435; 10437; 10438; 10439; 10440; 10422; 10423; 10385; 10450; 10451; 10411; 10412; 10473; 10474; 10417; 10475; 10476; 10427; 10481; 10404; 10405; 10428; 10418; 10419; 10420; 10421; 10426; 10442; 10431; 10378; 10446; 10447; 10448; 10429; 10430; 10390; 10375; 10371; 10361; 10389; 10391; 10467; 10400; 10463; 10464; 10465; 10472; 10466; 10393; 10392; 10402; 10403; 10401; 10477; 10478; 10470; 10471; 10399; 10468chr20:1915454:C:T; chr20:1914226:T:C; chr20:1914235:T:C; chr20:1913961:A:G; chr20:1913984:G:A; chr20:1914043:G:T; chr20:1914044:T:A; chr20:1913960:C:T; chr20:1914531:C:T; chr20:1913117:C:G; chr20:1914887:T:C; chr20:1914892:C:T; chr20:1914893:T:G; chr20:1914955:C:T; chr20:1914965:G:A; chr20:1913938:T:C; chr20:1915009:T:C; chr20:1915012:A:T; chr20:1914975:C:A; chr20:1914984:T:C; chr20:1914518:T:C; chr20:1914745:A:T; chr20:1914671:C:T; chr20:1914538:A:T; chr20:1914646:A:G; chr20:1914264:G:C; chr20:1914274:T:C; chr20:1914627:T:C; chr20:1913101:T:C; chr20:1915598:A:G; chr20:1914547:C:T; chr20:1914331:A:G; chr20:1914425:C:T; chr20:1914428:A:G; chr20:1913334:G:C; chr20:1913340:C:G; chr20:1914924:C:T; chr20:1914572:T:C; chr20:1914498:T:A; chr20:1914501:C:T; chr20:1915317:A:G; chr20:1915319:C:A; chr20:1913821:T:A; chr20:1914456:G:A; chr20:1913169:G:A; chr20:1915642:A:G; chr20:1914143:T:C; chr20:1914201:C:G; chr20:1914250:T:G; chr20:1914370:G:A; chr20:1914695:C:T; chr20:1914712:C:T; chr20:1914819:T:TTA; chr20:1914822:G:GAA; chr20:1914838:ACT:A; chr20:1914998:T:C; chr20:1915021:A:C; chr20:1915022:C:A; chr20:1915027:T:C; chr20:1915059:C:T; chr20:1915067:T:TAA; chr20:1915068:G:A; chr20:1915413:G:A; chr20:1915414:T:C; chr20:1913163:G:A; chr20:1913669:C:T; chr20:1913689:G:A; chr20:1915755:T:A; chr20:1916761:A:G; chr20:1916796:C:T; chr20:1913138:G:A; chr20:1914466:AG:A; chr20:1914473:C:G; chr20:1914479:C:A; chr20:1914489:A:G; chr20:1910344:CTT:C; chr20:1915169:A:G; chr20:1914582:G:GC; chr20:1914584:GGC:G; chr20:1915148:G:A; chr20:1915150:T:C; chr20:1915151:G:A; chr20:1912475:G:A; chr20:1915243:G:C; chr20:1909212:A:G; chr20:1904453:C:G; chr20:1908219:A:G; chr20:1915189:C:T; chr20:1915196:T:C; chr20:1914707:CT:C; chr20:1914713:A:G; chr20:1914721:C:G; chr20:1914729:G:C; chr20:1914731:T:C; chr20:1915167:A:T; chr20:1915174:C:T; chr20:1915338:C:A; chr20:1915344:G:A; chr20:1914774:T:Achr20:1915755:T:Acoloc_sets:Y7_Y8_Y9_Y11_Y13:MergeCS1
In [12]:
# effect sign for each coloc sets
get_effect_sign_csets(cb_res)
$`coloc_sets:Y7_Y8_Y9_Y11_Y13:MergeCS1` =
A data.frame: 99 x 6
variantsDLPFCACPCCpQTLAC_unproductive
<chr><dbl><dbl><dbl><dbl><dbl>
chr20:1915755:T:Achr20:1915755:T:A -6.025777-16.04639-14.32299-32.019285.902967
chr20:1914671:C:Tchr20:1914671:C:T -6.094837-16.10284-14.42522-31.551716.061435
chr20:1914531:C:Tchr20:1914531:C:T -6.147011-15.99679-14.19473-31.650306.054298
chr20:1914745:A:Tchr20:1914745:A:T -6.102105-16.29831-14.20616-31.458075.924289
chr20:1914518:T:Cchr20:1914518:T:C -6.099531-16.04732-14.19473-31.650305.958221
chr20:1914143:T:Cchr20:1914143:T:C -6.031888-16.15446-14.25394-31.551715.965569
chr20:1914201:C:Gchr20:1914201:C:G -6.031888-16.15446-14.25394-31.551715.965569
chr20:1914250:T:Gchr20:1914250:T:G -6.031888-16.15446-14.25394-31.551715.965569
chr20:1914370:G:Achr20:1914370:G:A -6.031888-16.15446-14.25394-31.551715.965569
chr20:1914695:C:Tchr20:1914695:C:T -6.031888-16.15446-14.25394-31.551715.965569
chr20:1914712:C:Tchr20:1914712:C:T -6.031888-16.15446-14.25394-31.551715.965569
chr20:1914819:T:TTAchr20:1914819:T:TTA-6.031888-16.15446-14.25394-31.551715.965569
chr20:1914822:G:GAAchr20:1914822:G:GAA-6.031888-16.15446-14.25394-31.551715.965569
chr20:1914838:ACT:Achr20:1914838:ACT:A-6.031888-16.15446-14.25394-31.551715.965569
chr20:1914998:T:Cchr20:1914998:T:C -6.031888-16.15446-14.25394-31.551715.965569
chr20:1915021:A:Cchr20:1915021:A:C -6.031888-16.15446-14.25394-31.551715.965569
chr20:1915022:C:Achr20:1915022:C:A -6.031888-16.15446-14.25394-31.551715.965569
chr20:1915027:T:Cchr20:1915027:T:C -6.031888-16.15446-14.25394-31.551715.965569
chr20:1915059:C:Tchr20:1915059:C:T -6.031888-16.15446-14.25394-31.551715.965569
chr20:1915067:T:TAAchr20:1915067:T:TAA-6.031888-16.15446-14.25394-31.551715.965569
chr20:1915068:G:Achr20:1915068:G:A -6.031888-16.15446-14.25394-31.551715.965569
chr20:1915454:C:Tchr20:1915454:C:T -6.382132-16.22510-13.75496-29.434985.607707
chr20:1914646:A:Gchr20:1914646:A:G -6.080731-15.99171-14.25394-31.551716.084051
chr20:1913334:G:Cchr20:1913334:G:C -6.058156-16.01912-14.25394-31.551716.061220
chr20:1913340:C:Gchr20:1913340:C:G -6.058156-16.01912-14.25394-31.551716.061220
chr20:1914331:A:Gchr20:1914331:A:G -6.063924-16.06328-14.26664-31.551715.962064
chr20:1914924:C:Tchr20:1914924:C:T -6.058575-16.15446-14.23899-31.354315.965569
chr20:1913669:C:Tchr20:1913669:C:T -6.025777-16.04639-14.32299-31.578015.902967
chr20:1913689:G:Achr20:1913689:G:A -6.025777-16.04639-14.32299-31.578015.902967
chr20:1916761:A:Gchr20:1916761:A:G -6.025777-16.04639-14.32299-31.578015.902967
.....................
chr20:1910344:CTT:Cchr20:1910344:CTT:C-6.010374-16.12044-14.02453-30.861275.836147
chr20:1914887:T:Cchr20:1914887:T:C -6.129866-16.04444-14.07364-30.401505.873669
chr20:1914892:C:Tchr20:1914892:C:T -6.129866-16.04444-14.07364-30.401505.873669
chr20:1914893:T:Gchr20:1914893:T:G -6.129866-16.04444-14.07364-30.401505.873669
chr20:1914582:G:GCchr20:1914582:G:GC -6.003597-15.87570-13.95403-31.235826.045859
chr20:1914584:GGC:Gchr20:1914584:GGC:G-6.003597-15.87570-13.95403-31.235826.045859
chr20:1913117:C:Gchr20:1913117:C:G -6.133573-16.20664-13.87640-29.803995.806558
chr20:1909212:A:Gchr20:1909212:A:G -5.947099-16.11526-13.85664-30.732755.777203
chr20:1908219:A:Gchr20:1908219:A:G -5.904821-16.17955-13.82581-30.453735.759667
chr20:1904453:C:Gchr20:1904453:C:G -5.937948-16.11373-13.85664-30.453735.698166
chr20:1913101:T:Cchr20:1913101:T:C -6.071202-16.04778-13.93256-29.540925.865323
chr20:1913138:G:Achr20:1913138:G:A -6.010739-16.20664-13.73750-29.440975.806558
chr20:1915169:A:Gchr20:1915169:A:G -6.006899-15.90406-14.14565-30.187725.810255
chr20:1913938:T:Cchr20:1913938:T:C -6.124972-15.75178-13.76929-31.303345.830852
chr20:1915148:G:Achr20:1915148:G:A -5.996166-16.01994-13.85752-29.992915.911580
chr20:1915150:T:Cchr20:1915150:T:C -5.996166-16.01994-13.85752-29.992915.911580
chr20:1915151:G:Achr20:1915151:G:A -5.996166-16.01994-13.85752-29.992915.911580
chr20:1915243:G:Cchr20:1915243:G:C -5.964609-15.88497-14.08698-30.577705.760523
chr20:1915167:A:Tchr20:1915167:A:T -5.927961-15.99179-14.05601-30.187725.773574
chr20:1913169:G:Achr20:1913169:G:A -6.029141-15.97150-13.69993-29.867295.870329
chr20:1913163:G:Achr20:1913163:G:A -6.022924-15.96875-13.77244-29.867295.809400
chr20:1913961:A:Gchr20:1913961:A:G -6.160020-15.59101-13.85381-31.185395.777678
chr20:1913984:G:Achr20:1913984:G:A -6.160020-15.59101-13.85381-31.185395.777678
chr20:1913960:C:Tchr20:1913960:C:T -6.153889-15.48377-13.92220-31.215185.713418
chr20:1915413:G:Achr20:1915413:G:A -6.026457-15.59500-13.57816-30.988495.674460
chr20:1915414:T:Cchr20:1915414:T:C -6.026457-15.59500-13.57816-30.988495.674460
chr20:1915189:C:Tchr20:1915189:C:T -5.892005-16.07657-13.78890-29.579975.698078
chr20:1915196:T:Cchr20:1915196:T:C -5.892005-16.07657-13.78890-29.579975.698078
chr20:1913821:T:Achr20:1913821:T:A -6.031327-15.67983-13.77084-30.440935.690846
chr20:1915174:C:Tchr20:1915174:C:T -5.805488-15.99179-13.90976-29.819785.773574
In [13]:
# LD between coloc sets
get_between_purity_simple(cb_res, gene.name = gene_id, path = '/data/colocalization/QTL_data/eQTL/')

Here, different colors refer to different 95% Colocalization Sets (CoS, a metric developed in ColocBoost indicating that there is 95% probabilty that this CoS captures a colocalization event). We only included ROSMAP data for this particular ColocBoost analysis. In this case, we observe cell specific eQTL, bulk sQTL colocalization on ROSMAP data with AD as two separate CoS, suggesting two putative causal signals. We did not detect colocalization with pQTL of statistical significance although from Section 1 there are some overlap with pQTL signals in fine-mapping CS, the overlapped variants in CS have small PIP.

Section 3: Refinement of colocalized loci with other AD GWAS¶

Here we refine the colocalization with other AD GWAS to iron out any heterogeniety between studies (heterogeniety can come from many sources), to get additional candidate loci from these more heterogenous sources as candidates to study.

In [14]:
AD_cohorts <- c('AD_Jansen_2021', 'AD_Bellenguez_EADB_2022', 'AD_Bellenguez_EADI_2022',
             'AD_Kunkle_Stage1_2019', 'AD_Wightman_Excluding23andMe_2021',
             'AD_Wightman_ExcludingUKBand23andME_2021', 'AD_Wightman_Full_2021')
cb_ad <- plot_cb(cb_res = cb_res, cex.pheno = 1.5, x.phen = -0.2, add_gwas = TRUE, gene_id = gene_id, cohorts = AD_cohorts)
No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.Error : File '/data/GWAS/ADGWAS_sumstats/20_854451-2517368.RSS_QC_RAISS_imputed.AD_Kunkle_Stage1_2019.sumstats.tsv.gz' does not exist or is non-readable. getwd()=='/data/interactive_analysis/hs3163/GIT/xqtl-paper/AD_targets/SIRPA'
No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.
No description has been provided for this image
In [15]:
pdf('plots/SIRPA/sec3.colocboost_res_allad.pdf', width = 10, height = 5)
replayPlot(cb_ad$p)
dev.off()
pdf: 2

Section 4: Assessment of multi-context xQTL effect sizes¶

Option 1: ColocBoost + MASH¶

Use colocboost variants and check for mash posterior contrast to see if the effect size are shared or specific or even opposite. Advantage is that colocboost result is AD GWAS informed; issue is that marginal posterior effects is not always the joint

In [16]:
mash_p <- mash_plot(gene_name = 'SIRPA')

options(repr.plot.width = 10, repr.plot.height = 10)

for (mash_p_tmp in mash_p) {
    print(mash_p_tmp)
}

Option 2: mvSuSiE¶

Use mvSuSiE multicontext fine-mapping results --- the bubble plot to check posterior effects. Issue is that we don't have this results yet, and this is limited to one cohort at a time, without information from AD.

We should go for option 1 by default and if we want to make claim about opposite effect size we double-check with mvSuSiE multicontext analysis.

Section 5: Multi-context causal TWAS (including conventional TWAS and MR)¶

The most updated version of cTWAS analysis are under path s3://statfungen/ftp_fgc_xqtl/analysis_result/cTWAS/

TWAS results¶

We report TWAS from all contexts and methods from the pipeline. Here we will filter it down to the best performing methods and only keep contexts that are significant.

In [17]:
plot_TWAS_res(gene_id = gene_id, gene_name = gene_name)
No description has been provided for this image

MR results¶

This is only available for genes that are deemed significant in TWAS and have summary statistics available for effect size and standard errors in GWAS, in addition to z-scores --- current version does not support z-scores although we will soon also support z-scores in MR using MAF from reference panel.

cTWAS results¶

To be updated soon.

Section 6: Context specific multi-gene fine-mapping¶

A quick analysis: using the xQTL-AD summary table (flatten table)¶

We extract from xQTL-AD summary table the variants to get other genes also have CS with the variants shared by target gene and AD.

In [18]:
multigene_flat <- get_multigene_multicontext_flatten('Fungen_xQTL_allQTL.overlapped.gwas.export.SIRPA.rds', sQTL = 'no_MSBB')
multigene_flat
A data.frame: 60 x 6
gene_id#chrstartendgene_namecontexts
<chr><chr><int><int><chr><chr>
ENSG00000088812chr2034710173471018ATRN Mic_13_Kellis_eQTL,ROSMAP_PCC_sQTL,ROSMAP_DLPFC_sQTL
ENSG00000088827chr2037125993712600SIGLEC1 MiGA_THA_eQTL,ROSMAP_AC_sQTL
ENSG00000088833chr2014738411473842NSFL1C MiGA_THA_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL
ENSG00000088836chr2032395583239559SLC4A11 MiGA_SVZ_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL,ROSMAP_DLPFC_sQTL
ENSG00000088854chr2034076683407669C20orf194 Inh_Kellis_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL
ENSG00000088876chr2025247012524702ZNF343 MiGA_GTS_eQTL
ENSG00000088881chr2026928732692874EBF4 MiGA_GTS_eQTL,ROSMAP_AC_sQTL,ROSMAP_DLPFC_sQTL,ROSMAP_PCC_sQTL
ENSG00000088882chr2028006262800627CPXM1 ROSMAP_AC_sQTL
ENSG00000088888chr2038467983846799MAVS MiGA_GTS_eQTL,Exc_mega_eQTL,ROSMAP_DLPFC_sQTL
ENSG00000088899chr2031735913173592LZTS3 MiGA_THA_eQTL,ROSMAP_PCC_sQTL,ROSMAP_DLPFC_sQTL
ENSG00000089012chr2016577781657779SIRPG MSBB_BM36_pQTL,PCC_DeJager_eQTL
ENSG00000101220chr2037677803767781C20orf27 MiGA_GTS_eQTL,Inh_Kellis_eQTL,ROSMAP_AC_sQTL,ROSMAP_DLPFC_sQTL,STARNET_eQTL
ENSG00000101222chr2037814473781448SPEF1 MiGA_GTS_eQTL,ROSMAP_DLPFC_sQTL
ENSG00000101224chr2037867713786772CDC25B DLPFC_DeJager_eQTL,PCC_DeJager_eQTL,AC_DeJager_eQTL,ROSMAP_AC_sQTL,ROSMAP_DLPFC_sQTL,STARNET_eQTL
ENSG00000101236chr2040155574015558RNF24 MiGA_GFM_eQTL,Inh_DeJager_eQTL,Inh_mega_eQTL
ENSG00000101255chr20 362834 362835TRIB3 ROSMAP_AC_sQTL
ENSG00000101265chr2048236074823608RASSF2 MiGA_SVZ_eQTL
ENSG00000101276chr20 776014 776015SLC52A3 MiGA_GTS_eQTL
ENSG00000101282chr2010023101002311RSPO4 AC_DeJager_eQTL
ENSG00000101290chr2051268785126879CDS2 ROSMAP_PCC_sQTL
ENSG00000101298chr2012662791266280SNPH MiGA_GTS_eQTL,MiGA_SVZ_eQTL
ENSG00000101307chr2016200601620061SIRPB1 Knight_eQTL,BM_10_MSBB_eQTL,BM_22_MSBB_eQTL,BM_36_MSBB_eQTL,BM_44_MSBB_eQTL,MSBB_BM36_pQTL,DLPFC_DeJager_eQTL,PCC_DeJager_eQTL,AC_DeJager_eQTL
ENSG00000101361chr2026525922652593NOP56 MiGA_SVZ_eQTL,BM_22_MSBB_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL
ENSG00000101365chr2026642182664219IDH3B MiGA_SVZ_eQTL
ENSG00000125775chr2013291381329139SDCBP2 MiGA_SVZ_eQTL,MiGA_THA_eQTL,Exc_DeJager_eQTL,ROSMAP_PCC_sQTL,STARNET_eQTL
ENSG00000125817chr2037867393786740CENPB MiGA_GTS_eQTL,ROSMAP_DLPFC_sQTL
ENSG00000125818chr2011132391113240PSMF1 MiGA_GTS_eQTL,MiGA_THA_eQTL,Oli_Kellis_eQTL
ENSG00000125826chr20 407497 407498RBCK1 ROSMAP_PCC_sQTL
ENSG00000125834chr2021018262101827STK35 MiGA_THA_eQTL,DLPFC_DeJager_eQTL
ENSG00000125835chr2024708522470853SNRPB MiGA_SVZ_eQTL,ROSMAP_PCC_sQTL
ENSG00000125841chr20 346781 346782NRSN2 MiGA_THA_eQTL,ROSMAP_AC_sQTL,ROSMAP_DLPFC_sQTL,ROSMAP_PCC_sQTL
ENSG00000125843chr2038205233820524AP5S1 MiGA_GTS_eQTL,MiGA_SVZ_eQTL,MiGA_THA_eQTL,BM_36_MSBB_eQTL
ENSG00000125875chr20 462565 462566TBC1D20 DLPFC_DeJager_eQTL,Mic_Kellis_eQTL,Exc_Kellis_eQTL,Exc_mega_eQTL,Inh_mega_eQTL,ROSMAP_PCC_sQTL
ENSG00000125877chr2032088673208868ITPA MiGA_THA_eQTL,MSBB_BM36_pQTL,ROSMAP_AC_sQTL
ENSG00000125878chr20 610397 610398TCF15 AC_DeJager_eQTL
ENSG00000125895chr2011854141185415TMEM74B ROSMAP_AC_sQTL
ENSG00000132622chr2037326843732685HSPA12B ROSMAP_PCC_sQTL,ROSMAP_DLPFC_sQTL
ENSG00000132635chr2028411892841190PCED1A MiGA_SVZ_eQTL
ENSG00000132670chr2028641832864184PTPRA MiGA_GFM_eQTL,MiGA_SVZ_eQTL,MiGA_THA_eQTL,ROSMAP_AC_sQTL,ROSMAP_DLPFC_sQTL,ROSMAP_PCC_sQTL
ENSG00000149451chr2036822453682246ADAM33 DLPFC_DeJager_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL,ROSMAP_DLPFC_sQTL
ENSG00000149488chr2025365722536573TMC2 DLPFC_DeJager_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL
ENSG00000171867chr2046863494686350PRNP MiGA_GTS_eQTL
ENSG00000171873chr2042492864249287ADRA1D MiGA_THA_eQTL
ENSG00000177732chr20 325551 325552SOX12 MiGA_THA_eQTL,monocyte_ROSMAP_eQTL
ENSG00000185019chr2031601953160196UBOX5 MiGA_SVZ_eQTL
ENSG00000186458chr20 257723 257724DEFB132 MiGA_GTS_eQTL
ENSG00000196209chr2014915861491587SIRPB2 MiGA_SVZ_eQTL,PCC_DeJager_eQTL,monocyte_ROSMAP_eQTL
ENSG00000196476chr20 290777 290778C20orf96 MiGA_GFM_eQTL,BM_36_MSBB_eQTL,ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL
ENSG00000198171chr2032046843204685DDRGK1 ROSMAP_AC_sQTL
ENSG00000198326chr2028163012816302TMEM239 MiGA_GTS_eQTL
ENSG00000215251chr2031598643159865FASTKD5 MiGA_SVZ_eQTL
ENSG00000215305chr2028407022840703VPS16 MiGA_GTS_eQTL,MiGA_SVZ_eQTL,ROSMAP_DLPFC_sQTL
ENSG00000215595chr2012034531203454C20orf202 MiGA_SVZ_eQTL
ENSG00000244588chr2012260551226056RAD21L1 ROSMAP_AC_sQTL,ROSMAP_PCC_sQTL
ENSG00000256566chr2025089062508907AL049650.1ROSMAP_AC_sQTL,ROSMAP_DLPFC_sQTL
ENSG00000260861chr2016200081620009AL049634.2BM_10_MSBB_eQTL,BM_22_MSBB_eQTL,BM_36_MSBB_eQTL,BM_44_MSBB_eQTL,DLPFC_DeJager_eQTL,PCC_DeJager_eQTL,AC_DeJager_eQTL,STARNET_eQTL
ENSG00000270299chr20 675799 675800AL121758.1ROSMAP_PCC_sQTL
ENSG00000271303chr20 653199 653200SRXN1 Knight_eQTL,AC_DeJager_eQTL,ROSMAP_PCC_sQTL
ENSG00000274322chr2013930951393096AL136531.2ROSMAP_DLPFC_sQTL
ENSG00000286022chr2022073272207328AL121899.2ROSMAP_AC_sQTL

Other genes implicated are PROC and HS6ST1 in MiGA cohort which may share causal eQTL with SIRPA. Further look into the data-set --- using these genes as targets and repeating what we did above for SIRPA --- might be needed to establish a more certain conclusion.

Alternatively, we may be able to apply a multi-gene statistical fine-mapping test on SIRPA region to find these genes, as you will see in the section below.

A statistically solid approach: mvSuSiE multi-gene analysis¶

This multi-gene fine-mapping analysis was done for each xQTL context separately. We will need to check the results for all contexts where this gene has an xQTL, in order to identify if there are other genes also sharing the same xQTL with this target gene. We included other genes in the same TAD window along with this gene, and extended it into a sliding window approach to include multiple TADs just in case. You need to check the sliding windows belongs to that gene (TSS) on analysis repo.

In [19]:
sliding_windows <- target_gene_info$gene_info$sliding_windows %>% strsplit(., ',') %>% unlist %>% as.character
sliding_windows
  1. 'chr20:0-7123030'
  2. 'chr20:2043621-9019805'
  3. 'chr20:4114953-9968360'

The most updated version of mvSuSiE multi-gene results are under path s3://statfungen/ftp_fgc_xqtl/analysis_result/mvsusie_multi_gene_test/multi_gene/ Currently it is still WIP. You can revisit this later when we prompt you to. Here is an example for SIRPA:

In [20]:
mnm_gene <- list()
for (window in sliding_windows) {
    mnm_gene_tmp <- NULL
    mnm_gene_tmp <- tryCatch(
        readRDS(paste0('/data/analysis_result/mvsusie_multi_gene/multi_gene/ROSMAP_multi_gene.', window, '.mnm.rds')),
        error = function(e) NULL
    )
    
    if (!is.null(mnm_gene_tmp)) {
        if(target_gene_info$gene_info$region_id %in% mnm_gene_tmp$mvsusie_fitted$condition_names){
        tryCatch({
            p <- mvsusieR::mvsusie_plot(mnm_gene_tmp$mvsusie_fitted, sentinel_only = F, add_cs = T)
            print(p)  # This ensures the plot is displayed in JupyterLab
        }, error = function(e) NULL)
        } else {
            message('There is mnm result for sliding window ',window,', but not include target gene ', gene_name, ' in CS')
        }
        mnm_gene <- append(mnm_gene, list(mnm_gene_tmp))
    }
}

In this case, there is no statistical evidence for SIRPA sharing any of its xQTL with other genes in ROSMAP Microglia data we looked into; although we have not analyzed MiGA this way yet (which showed some potential signals from the quick analysis above).

Section 7: Epigenomic QTL and their target regions¶

fsusie, see notebook

Generate a crude plot to determined whether the story is interesting¶

This is a crude version of the case study plot which shows the fsusie Effect (colored line), the gene body (black arrow), the epi-QTL (large dots with the same color as the effects) and ADGWAS cs position (small red dots).

Only produce the refine plot if we can see either:

  1. There are sharing snp between epi-QTL and AD CS
  2. There are the AD CS located within one of the effect range
  3. The crude plot suggest something interesting
In [9]:
options(repr.plot.width = 40, repr.plot.height = 40)

 ggplot() + theme_bw() + facet_grid(cs_coverage_0.95 + study + region ~ ., labeller = labeller(.rows = function(x) gsub("([_:,-])", "\n", x)), scale = "free_y") +

      theme(text = element_text(size = 20), strip.text.y = element_text(size = 25, angle = 0.5)) +
     # xlim(view_win) +
      ylab("Estimated effect") +
   #   geom_line(data = haQTL_df %>% mutate(study = "haQTL effect") %>% filter(CS == 5),
    #            aes_string(y = "fun_plot", x = "x", col = "CS"), size = 4, col = "#00AEEF") +
  geom_line(data = effect_of_interest ,
                aes_string(y = "fun_plot", x = "x", col = "cs_coverage_0.95"), size = 2) +  
    geom_point(data = effect_of_interest ,
                aes_string(y = "pip", x = "pos", col = "cs_coverage_0.95"), size = 10) +
    theme(text = element_text(size = 40), strip.text.y = element_text(size = 15, angle = 0.5), 
            axis.text.x = element_text(size = 40), axis.title.x = element_text(size = 40)) +
      xlab("Position") +
      ylab("Estimated\neffect") +
      geom_segment(arrow = arrow(length = unit(1, "cm")), aes(x = gene_start, xend = gene_end, y = 1, yend = 1), size = 6,
                  data = tar_gene_info$gene_info, alpha = 0.3) +
      geom_text(aes(x = (gene_start + gene_end) / 2, y = 1 , label = gene_name), size = 10, 
              data = tar_gene_info$gene_info)+
        geom_point(aes(x = pos, y = pip  ) ,color = "red", data = flatten_table%>%filter( str_detect(study,"AD_") , cs_coverage_0.95 != 0  )%>%mutate(AD_study = study%>%str_replace_all("_","\n" ))%>%select(-study,-region,-cs_coverage_0.95) ) 
No description has been provided for this image

Section 8: Context focused validation in other xQTL data¶

see notebook

add fake version for now, so you don't have to refer to above link

Background: our "discovery set" is ROSMAP but we have additional "validation" sets including:

  • STARNET
  • MiGA
  • KnightADRC
  • MSBB
  • metaBrain
  • UKB pQTL

TODO:

  • Get from Carlos WashU CSF based resource (pQTL and metabolomic QTL)

This section shows verification of findings from these data-sets. In principle we should check them through sections 1-6 more formally. In practice we will start with colocalization via colocboost --- since our study is genetics (variant and loci level) focused. We can selectively follow them up for potentially intereting validations. We therefore only demonstrate validation via colocboost as a starting point.

In [5]:
finempping_contexts <- readRDS(paste0(gene_name, '_finemapping_contexts.rds')) # from sec1
In [5]:
finempping_contexts <- readRDS(paste0(gene_name, '_finemapping_contexts.rds')) # from sec1
In [6]:
finempping_contexts <- get_norosmap_contexts(finempping_contexts)
In [7]:
cb_contexts <- plot_cb(cb_res = cb_res, cex.pheno = 1.5, x.phen = -0.2, add_QTL = TRUE, cohorts = finempping_contexts, gene_id = gene_id)
No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.No pvalue cutoff. Extract all variants names.
No description has been provided for this image

Section 9: Non-linear effects of xQTL¶

see notebook

APOE interaction¶

In [10]:
options(repr.plot.width=6, repr.plot.height=6)

ggplot(SIRPA_int_res, aes(x = variant_id, y = qvalue_interaction)) +
  geom_point(alpha = 0.7, size = 6) +
  labs(title = "qvalue for SIRPA csets in interaction association nalysis",
       x = "Gene Name",
       y = "qvalue_interaction",
       size = "qvalue_interaction") +
  theme_minimal(base_size = 14) +
  theme(panel.background = element_blank(),
        panel.grid.major = element_line(color = "grey80"),
        legend.position = NULL,
        axis.text.x = element_text(angle = 45, hjust = 1))  + ylim(0,1)
  # scale_color_manual(values = colorRampPalette(brewer.pal(8, "Set1"))(length(unique(flat_var$gene_name))))
ggsave('plots/SIRPA/sec11.interaction_association_SIRPA_lessPIP25.pdf', height = 5, width = 8) 
No description has been provided for this image

In conclusion, there is no interaction QTL with APOE identified.

Section 10: in silico functional studies in iPSC model¶

see notebook

In [11]:
vars_p
In [13]:
apoe_p

Section 11: Functional annotations of selected loci¶

see notebook

TODO

  • Touch base with Ryan on the snATAC annotations
  • Run this by Pavel to see if there are additional comments on how we do this
In [ ]:
 

Section 12: Candidate loci as trans-xQTL¶

see notebook

In [9]:
options(repr.plot.width=12, repr.plot.height=6)
if(!is.null(flat_var)){
   p =  ggplot(flat_var, aes(x = gene_name, y = pip, size = pip)) +
      geom_point(alpha = 0.7) +
      labs(title = paste0("PIP values for trans fine mapped Genes in ", gene_name ," csets with AD"),
           x = "Gene Name",
           y = "PIP",
           size = "PIP",
           color = "CS Coverage 0.95 Min Corr") +
      theme_minimal(base_size = 14) +
      theme(panel.background = element_blank(),
            panel.grid.major = element_line(color = "grey80"),
            legend.position = NULL,
            axis.text.x = element_text(angle = 45, hjust = 1))  
      # scale_color_manual(values = colorRampPalette(brewer.pal(8, "Set1"))(length(unique(flat_var$gene_name))))
    ggsave(paste0('plots/SIRPA/sec12.trans_fine_mapping_',gene_name,'.pdf'),p, height = 5, width = 8)
    p
    } else{
    message('There are no detectable trans signals for ', gene_name)
}

Creative thinking: generate hypothesis, search in literature, raise questions to discuss¶

You can now generate some preliminary hypotheses based on the above results. Next, you should search for evidence in the literature to support or refine these hypotheses and identify additional analyses needed to confirm them.