Last updated: 2021-09-09

Checks: 6 1

Knit directory: ctwas_applied/

This reproducible R Markdown analysis was created with workflowr (version 1.6.2). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.


The R Markdown file has unstaged changes. To know which version of the R Markdown file created these results, you’ll want to first commit it to the Git repo. If you’re still working on the analysis, you can ignore this warning. When you’re finished, you can run wflow_publish to commit the R Markdown file and build the HTML.

Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.

The command set.seed(20210726) was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.

Great job! Recording the operating system, R version, and package versions is critical for reproducibility.

Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.

Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.

Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.

The results in this page were generated with repository version 59e5f4d. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.

Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish or wflow_git_commit). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:


Unstaged changes:
    Modified:   analysis/ukb-d-30500_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30600_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30610_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30620_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30630_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30640_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30650_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30660_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30670_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30680_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30690_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30700_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30710_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30720_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30730_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30740_irnt_Liver.Rmd
    Modified:   analysis/ukb-d-30750_irnt_Liver.Rmd

Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.


These are the previous versions of the repository in which changes were made to the R Markdown (analysis/ukb-d-30750_irnt_Liver.Rmd) and HTML (docs/ukb-d-30750_irnt_Liver.html) files. If you’ve configured a remote Git repository (see ?wflow_git_remote), click on the hyperlinks in the table below to view the files as they were in that past version.

File Version Author Date Message
Rmd cbf7408 wesleycrouse 2021-09-08 adding enrichment to reports
html cbf7408 wesleycrouse 2021-09-08 adding enrichment to reports
Rmd 4970e3e wesleycrouse 2021-09-08 updating reports
html 4970e3e wesleycrouse 2021-09-08 updating reports
Rmd 627a4e1 wesleycrouse 2021-09-07 adding heritability
Rmd dfd2b5f wesleycrouse 2021-09-07 regenerating reports
html dfd2b5f wesleycrouse 2021-09-07 regenerating reports
Rmd 61b53b3 wesleycrouse 2021-09-06 updated PVE calculation
html 61b53b3 wesleycrouse 2021-09-06 updated PVE calculation
Rmd 837dd01 wesleycrouse 2021-09-01 adding additional fixedsigma report
Rmd d0a5417 wesleycrouse 2021-08-30 adding new reports to the index
Rmd 0922de7 wesleycrouse 2021-08-18 updating all reports with locus plots
html 0922de7 wesleycrouse 2021-08-18 updating all reports with locus plots
html 1c62980 wesleycrouse 2021-08-11 Updating reports
Rmd 5981e80 wesleycrouse 2021-08-11 Adding more reports
html 5981e80 wesleycrouse 2021-08-11 Adding more reports
Rmd 05a98b7 wesleycrouse 2021-08-07 adding additional results
html 05a98b7 wesleycrouse 2021-08-07 adding additional results
html 03e541c wesleycrouse 2021-07-29 Cleaning up report generation
Rmd 276893d wesleycrouse 2021-07-29 Updating reports
html 276893d wesleycrouse 2021-07-29 Updating reports

Overview

These are the results of a ctwas analysis of the UK Biobank trait Glycated haemoglobin (quantile) using Liver gene weights.

The GWAS was conducted by the Neale Lab, and the biomarker traits we analyzed are discussed here. Summary statistics were obtained from IEU OpenGWAS using GWAS ID: ukb-d-30750_irnt. Results were obtained from from IEU rather than Neale Lab because they are in a standardard format (GWAS VCF). Note that 3 of the 34 biomarker traits were not available from IEU and were excluded from analysis.

The weights are mashr GTEx v8 models on Liver eQTL obtained from PredictDB. We performed a full harmonization of the variants, including recovering strand ambiguous variants. This procedure is discussed in a separate document. (TO-DO: add report that describes harmonization)

LD matrices were computed from a 10% subset of Neale lab subjects. Subjects were matched using the plate and well information from genotyping. We included only biallelic variants with MAF>0.01 in the original Neale Lab GWAS. (TO-DO: add more details [number of subjects, variants, etc])

Weight QC

TO-DO: add enhanced QC reporting (total number of weights, why each variant was missing for all genes)

qclist_all <- list()

qc_files <- paste0(results_dir, "/", list.files(results_dir, pattern="exprqc.Rd"))

for (i in 1:length(qc_files)){
  load(qc_files[i])
  chr <- unlist(strsplit(rev(unlist(strsplit(qc_files[i], "_")))[1], "[.]"))[1]
  qclist_all[[chr]] <- cbind(do.call(rbind, lapply(qclist,unlist)), as.numeric(substring(chr,4)))
}

qclist_all <- data.frame(do.call(rbind, qclist_all))
colnames(qclist_all)[ncol(qclist_all)] <- "chr"

rm(qclist, wgtlist, z_gene_chr)

#number of imputed weights
nrow(qclist_all)
[1] 10901
#number of imputed weights by chromosome
table(qclist_all$chr)

   1    2    3    4    5    6    7    8    9   10   11   12   13   14   15 
1070  768  652  417  494  611  548  408  405  434  634  629  195  365  354 
  16   17   18   19   20   21   22 
 526  663  160  859  306  114  289 
#proportion of imputed weights without missing variants
mean(qclist_all$nmiss==0)
[1] 0.8366205

Load ctwas results

#load ctwas results
ctwas_res <- data.table::fread(paste0(results_dir, "/", analysis_id, "_ctwas.susieIrss.txt"))

#make unique identifier for regions
ctwas_res$region_tag <- paste(ctwas_res$region_tag1, ctwas_res$region_tag2, sep="_")

#compute PVE for each gene/SNP
ctwas_res$PVE = ctwas_res$susie_pip*ctwas_res$mu2/sample_size #check PVE calculation

#separate gene and SNP results
ctwas_gene_res <- ctwas_res[ctwas_res$type == "gene", ]
ctwas_gene_res <- data.frame(ctwas_gene_res)
ctwas_snp_res <- ctwas_res[ctwas_res$type == "SNP", ]
ctwas_snp_res <- data.frame(ctwas_snp_res)

#add gene information to results
sqlite <- RSQLite::dbDriver("SQLite")
db = RSQLite::dbConnect(sqlite, paste0("/project2/compbio/predictdb/mashr_models/mashr_", weight, ".db"))
query <- function(...) RSQLite::dbGetQuery(db, ...)
gene_info <- query("select gene, genename from extra")
gene_info <- query("select gene, genename, gene_type from extra")
RSQLite::dbDisconnect(db)

ctwas_gene_res <- cbind(ctwas_gene_res, gene_info[sapply(ctwas_gene_res$id, match, gene_info$gene), c("genename", "gene_type")])

#add z score to results
load(paste0(results_dir, "/", analysis_id, "_expr_z_gene.Rd"))
ctwas_gene_res$z <- z_gene[ctwas_gene_res$id,]$z

#load(paste0(results_dir, "/", analysis_id, "_expr_z_snp.Rd")) #for new version, stored after harmonization
z_snp <- readRDS(paste0(results_dir, "/", trait_id, ".RDS")) #for old version, unharmonized

z_snp <- z_snp[z_snp$id %in% ctwas_snp_res$id,] #subset snps to those included in analysis, note some are duplicated, need to match which allele was used
ctwas_snp_res$z <- z_snp$z[match(ctwas_snp_res$id, z_snp$id)] #for duplicated snps, this arbitrarily uses the first allele
ctwas_snp_res$z_flag <- as.numeric(ctwas_snp_res$id %in% z_snp$id[duplicated(z_snp$id)]) #mark the unclear z scores, flag=1

#formatting and rounding for tables
ctwas_gene_res$z <- round(ctwas_gene_res$z,2)
ctwas_snp_res$z <- round(ctwas_snp_res$z,2)
ctwas_gene_res$susie_pip <- round(ctwas_gene_res$susie_pip,3)
ctwas_snp_res$susie_pip <- round(ctwas_snp_res$susie_pip,3)
ctwas_gene_res$mu2 <- round(ctwas_gene_res$mu2,2)
ctwas_snp_res$mu2 <- round(ctwas_snp_res$mu2,2)
ctwas_gene_res$PVE <- signif(ctwas_gene_res$PVE, 2)
ctwas_snp_res$PVE <- signif(ctwas_snp_res$PVE, 2)

#merge gene and snp results with added information
ctwas_gene_res$z_flag=NA
ctwas_snp_res$genename=NA
ctwas_snp_res$gene_type=NA

ctwas_res <- rbind(ctwas_gene_res,
                   ctwas_snp_res[,colnames(ctwas_gene_res)])

#store columns to report
report_cols <- colnames(ctwas_gene_res)[!(colnames(ctwas_gene_res) %in% c("type", "region_tag1", "region_tag2", "cs_index", "gene_type", "z_flag", "id", "chrom", "pos"))]
first_cols <- c("genename", "region_tag")
report_cols <- c(first_cols, report_cols[!(report_cols %in% first_cols)])

report_cols_snps <- c("id", report_cols[-1])

#get number of SNPs from s1 results; adjust for thin
ctwas_res_s1 <- data.table::fread(paste0(results_dir, "/", analysis_id, "_ctwas.s1.susieIrss.txt"))
n_snps <- sum(ctwas_res_s1$type=="SNP")/thin
rm(ctwas_res_s1)

Check convergence of parameters

library(ggplot2)
library(cowplot)

********************************************************
Note: As of version 1.0.0, cowplot does not change the
  default ggplot2 theme anymore. To recover the previous
  behavior, execute:
  theme_set(theme_cowplot())
********************************************************
load(paste0(results_dir, "/", analysis_id, "_ctwas.s2.susieIrssres.Rd"))
  
df <- data.frame(niter = rep(1:ncol(group_prior_rec), 2),
                 value = c(group_prior_rec[1,], group_prior_rec[2,]),
                 group = rep(c("Gene", "SNP"), each = ncol(group_prior_rec)))
df$group <- as.factor(df$group)

df$value[df$group=="SNP"] <- df$value[df$group=="SNP"]*thin #adjust parameter to account for thin argument

p_pi <- ggplot(df, aes(x=niter, y=value, group=group)) +
  geom_line(aes(color=group)) +
  geom_point(aes(color=group)) +
  xlab("Iteration") + ylab(bquote(pi)) +
  ggtitle("Prior mean") +
  theme_cowplot()

df <- data.frame(niter = rep(1:ncol(group_prior_var_rec), 2),
                 value = c(group_prior_var_rec[1,], group_prior_var_rec[2,]),
                 group = rep(c("Gene", "SNP"), each = ncol(group_prior_var_rec)))
df$group <- as.factor(df$group)
p_sigma2 <- ggplot(df, aes(x=niter, y=value, group=group)) +
  geom_line(aes(color=group)) +
  geom_point(aes(color=group)) +
  xlab("Iteration") + ylab(bquote(sigma^2)) +
  ggtitle("Prior variance") +
  theme_cowplot()

plot_grid(p_pi, p_sigma2)

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
#estimated group prior
estimated_group_prior <- group_prior_rec[,ncol(group_prior_rec)]
names(estimated_group_prior) <- c("gene", "snp")
estimated_group_prior["snp"] <- estimated_group_prior["snp"]*thin #adjust parameter to account for thin argument
print(estimated_group_prior)
        gene          snp 
0.0119417027 0.0002107847 
#estimated group prior variance
estimated_group_prior_var <- group_prior_var_rec[,ncol(group_prior_var_rec)]
names(estimated_group_prior_var) <- c("gene", "snp")
print(estimated_group_prior_var)
    gene      snp 
34.90073 20.38385 
#report sample size
print(sample_size)
[1] 344182
#report group size
group_size <- c(nrow(ctwas_gene_res), n_snps)
print(group_size)
[1]   10901 8697330
#estimated group PVE
estimated_group_pve <- estimated_group_prior_var*estimated_group_prior*group_size/sample_size #check PVE calculation
names(estimated_group_pve) <- c("gene", "snp")
print(estimated_group_pve)
      gene        snp 
0.01320015 0.10857332 
#compare sum(PIP*mu2/sample_size) with above PVE calculation
c(sum(ctwas_gene_res$PVE),sum(ctwas_snp_res$PVE))
[1] 0.06926647 2.53478335

Genes with highest PIPs

#distribution of PIPs
hist(ctwas_gene_res$susie_pip, xlim=c(0,1), main="Distribution of Gene PIPs")

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
#genes with PIP>0.8 or 20 highest PIPs
head(ctwas_gene_res[order(-ctwas_gene_res$susie_pip),report_cols], max(sum(ctwas_gene_res$susie_pip>0.8), 20))
      genename region_tag susie_pip      mu2     PVE      z
10849    DDAH2       6_26     1.000 14538.53 4.2e-02 -15.03
3212     CCND2       12_4     1.000   459.08 1.3e-03 -21.39
6498     ITGAD      16_25     0.999   169.89 4.9e-04 -11.72
5544     CNIH4      1_114     0.997    54.30 1.6e-04  -7.16
9390      GAS6      13_62     0.996   201.46 5.8e-04 -15.47
8493     OXSR1       3_27     0.985    46.83 1.3e-04   6.86
2546      LTBR       12_7     0.975    29.63 8.4e-05   3.97
3959     MYO5C      15_21     0.967    77.24 2.2e-04  -9.14
1783     ABCC1      16_15     0.967    42.46 1.2e-04   6.58
7264    ARFIP1       4_98     0.961    33.03 9.2e-05   5.29
9787   TMPRSS6      22_14     0.925    67.52 1.8e-04  -1.10
2048      GCDH      19_10     0.923    54.91 1.5e-04   9.77
4367   SEC14L4      22_10     0.921    58.44 1.6e-04  -7.56
6978    TRIM58      1_131     0.917    40.60 1.1e-04   9.12
10212     IL27      16_23     0.914   102.41 2.7e-04   9.95
889     EXOSC5      19_28     0.912    23.69 6.3e-05  -5.15
8565     NUDT4      12_55     0.897    33.35 8.7e-05   5.36
8811    SMIM19       8_37     0.886   230.45 5.9e-04  15.34
6558     AP3S2      15_41     0.881    67.86 1.7e-04   8.04
5291      SS18      18_13     0.880    29.83 7.6e-05  -5.05
11790   CYP2A6      19_28     0.873    24.79 6.3e-05   4.54
9442    ZNF438      10_23     0.857    22.66 5.6e-05   4.31
1231    PABPC4       1_24     0.850    67.10 1.7e-04  -8.67
3478     KLHL7       7_20     0.847    30.27 7.4e-05  -3.21
481      ITIH4       3_36     0.839    50.83 1.2e-04  -6.35
4736       HLX      1_112     0.823    22.69 5.4e-05   4.12
3883      PNKD      2_129     0.816    50.79 1.2e-04   7.18
9363      VMO1       17_4     0.814    20.89 4.9e-05   3.93
1723     KPNA3      13_21     0.808    23.76 5.6e-05   4.46

Genes with largest effect sizes

#plot PIP vs effect size
plot(ctwas_gene_res$susie_pip, ctwas_gene_res$mu2, xlab="PIP", ylab="mu^2", main="Gene PIPs vs Effect Size")

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
#genes with 20 largest effect sizes
head(ctwas_gene_res[order(-ctwas_gene_res$mu2),report_cols],20)
      genename region_tag susie_pip      mu2     PVE      z
10602     RNF5       6_26         0 59524.96 0.0e+00 -11.02
12683    HCP5B       6_24         0 55846.74 0.0e+00   7.15
11007     PPT2       6_26         0 51384.93 0.0e+00   9.85
10848    CLIC1       6_26         0 45048.81 0.0e+00 -12.36
11541      C4A       6_26         0 37312.58 0.0e+00 -13.10
10663   TRIM31       6_24         0 29354.79 0.0e+00  -7.56
10601     AGER       6_26         0 27971.73 0.0e+00   0.83
4833     FLOT1       6_24         0 27955.62 0.0e+00   8.58
10599   NOTCH4       6_26         0 27576.27 3.0e-08 -14.22
10626   MPIG6B       6_26         0 15225.12 0.0e+00   5.33
10849    DDAH2       6_26         1 14538.53 4.2e-02 -15.03
10625     MSH5       6_26         0 13658.53 0.0e+00  -7.89
10603   AGPAT1       6_26         0 13636.99 0.0e+00  10.19
10651    ABCF1       6_24         0 12864.86 0.0e+00   8.19
10137 HLA-DQA1       6_26         0 12796.82 0.0e+00  -8.32
11441    EGFL8       6_26         0 11537.38 0.0e+00   7.19
10616    EHMT2       6_26         0 11503.65 0.0e+00  -3.26
10606    FKBPL       6_26         0 11417.54 0.0e+00   5.23
5766   PPP1R18       6_24         0 11178.74 0.0e+00   7.58
11231 HLA-DQB2       6_26         0  9652.09 0.0e+00   7.55

Genes with highest PVE

#genes with 20 highest pve
head(ctwas_gene_res[order(-ctwas_gene_res$PVE),report_cols],20)
       genename region_tag susie_pip      mu2     PVE      z
10849     DDAH2       6_26     1.000 14538.53 0.04200 -15.03
3212      CCND2       12_4     1.000   459.08 0.00130 -21.39
8811     SMIM19       8_37     0.886   230.45 0.00059  15.34
9390       GAS6      13_62     0.996   201.46 0.00058 -15.47
6498      ITGAD      16_25     0.999   169.89 0.00049 -11.72
4990       CIR1      2_105     0.496   308.79 0.00045  15.74
5598      SCRN3      2_105     0.496   308.79 0.00045 -15.74
12661 LINC01126       2_27     0.675   162.38 0.00032 -16.23
10212      IL27      16_23     0.914   102.41 0.00027   9.95
3959      MYO5C      15_21     0.967    77.24 0.00022  -9.14
8506    FAM222B      17_17     0.491   132.01 0.00019 -12.06
9787    TMPRSS6      22_14     0.925    67.52 0.00018  -1.10
1231     PABPC4       1_24     0.850    67.10 0.00017  -8.67
6558      AP3S2      15_41     0.881    67.86 0.00017   8.04
4077     ARPC1B       7_61     0.782    69.96 0.00016   9.45
5544      CNIH4      1_114     0.997    54.30 0.00016  -7.16
4367    SEC14L4      22_10     0.921    58.44 0.00016  -7.56
2048       GCDH      19_10     0.923    54.91 0.00015   9.77
8493      OXSR1       3_27     0.985    46.83 0.00013   6.86
2810    PRKAR2A       3_35     0.711    56.88 0.00012  -8.61

Genes with largest z scores

#genes with 20 largest z scores
head(ctwas_gene_res[order(-abs(ctwas_gene_res$z)),report_cols],20)
            genename region_tag susie_pip      mu2     PVE      z
5322          FN3KRP      17_47     0.010   371.70 1.1e-05 -23.60
3212           CCND2       12_4     1.000   459.08 1.3e-03 -21.39
7755            FN3K      17_47     0.023   235.90 1.6e-05 -20.49
11681   RP11-673E1.1       4_94     0.001   253.57 6.5e-07 -20.38
10243           GYPE       4_94     0.001   252.78 5.1e-07  20.36
5321            TBCD      17_47     0.003   183.00 1.8e-06 -18.27
669           ATP11A      13_61     0.008   313.46 7.7e-06  18.01
8156            GYPA       4_94     0.000   140.06 1.8e-07 -17.17
12661      LINC01126       2_27     0.675   162.38 3.2e-04 -16.23
9646           SNAI3      16_53     0.001   292.88 1.2e-06 -15.96
4990            CIR1      2_105     0.496   308.79 4.5e-04  15.74
5598           SCRN3      2_105     0.496   308.79 4.5e-04 -15.74
9390            GAS6      13_62     0.996   201.46 5.8e-04 -15.47
8811          SMIM19       8_37     0.886   230.45 5.9e-04  15.34
10849          DDAH2       6_26     1.000 14538.53 4.2e-02 -15.03
10599         NOTCH4       6_26     0.000 27576.27 3.0e-08 -14.22
2661           HBS1L       6_89     0.000   218.04 1.2e-12  13.72
10667          HLA-G       6_24     0.000  6753.42 0.0e+00  13.58
12181 RP11-370I10.12      12_30     0.000   155.41 1.3e-10 -13.34
6177           SPC25      2_102     0.000   165.93 5.0e-09 -13.30

Comparing z scores and PIPs

#set nominal signifiance threshold for z scores
alpha <- 0.05

#bonferroni adjusted threshold for z scores
sig_thresh <- qnorm(1-(alpha/nrow(ctwas_gene_res)/2), lower=T)

#Q-Q plot for z scores
obs_z <- ctwas_gene_res$z[order(ctwas_gene_res$z)]
exp_z <- qnorm((1:nrow(ctwas_gene_res))/nrow(ctwas_gene_res))

plot(exp_z, obs_z, xlab="Expected z", ylab="Observed z", main="Gene z score Q-Q plot")
abline(a=0,b=1)

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
#plot z score vs PIP
plot(abs(ctwas_gene_res$z), ctwas_gene_res$susie_pip, xlab="abs(z)", ylab="PIP")
abline(v=sig_thresh, col="red", lty=2)

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
#proportion of significant z scores
mean(abs(ctwas_gene_res$z) > sig_thresh)
[1] 0.03935419
#genes with most significant z scores
head(ctwas_gene_res[order(-abs(ctwas_gene_res$z)),report_cols],20)
            genename region_tag susie_pip      mu2     PVE      z
5322          FN3KRP      17_47     0.010   371.70 1.1e-05 -23.60
3212           CCND2       12_4     1.000   459.08 1.3e-03 -21.39
7755            FN3K      17_47     0.023   235.90 1.6e-05 -20.49
11681   RP11-673E1.1       4_94     0.001   253.57 6.5e-07 -20.38
10243           GYPE       4_94     0.001   252.78 5.1e-07  20.36
5321            TBCD      17_47     0.003   183.00 1.8e-06 -18.27
669           ATP11A      13_61     0.008   313.46 7.7e-06  18.01
8156            GYPA       4_94     0.000   140.06 1.8e-07 -17.17
12661      LINC01126       2_27     0.675   162.38 3.2e-04 -16.23
9646           SNAI3      16_53     0.001   292.88 1.2e-06 -15.96
4990            CIR1      2_105     0.496   308.79 4.5e-04  15.74
5598           SCRN3      2_105     0.496   308.79 4.5e-04 -15.74
9390            GAS6      13_62     0.996   201.46 5.8e-04 -15.47
8811          SMIM19       8_37     0.886   230.45 5.9e-04  15.34
10849          DDAH2       6_26     1.000 14538.53 4.2e-02 -15.03
10599         NOTCH4       6_26     0.000 27576.27 3.0e-08 -14.22
2661           HBS1L       6_89     0.000   218.04 1.2e-12  13.72
10667          HLA-G       6_24     0.000  6753.42 0.0e+00  13.58
12181 RP11-370I10.12      12_30     0.000   155.41 1.3e-10 -13.34
6177           SPC25      2_102     0.000   165.93 5.0e-09 -13.30

Locus plots for genes and SNPs

ctwas_gene_res_sortz <- ctwas_gene_res[order(-abs(ctwas_gene_res$z)),]

n_plots <- 5
for (region_tag_plot in head(unique(ctwas_gene_res_sortz$region_tag), n_plots)){
  ctwas_res_region <-  ctwas_res[ctwas_res$region_tag==region_tag_plot,]
  start <- min(ctwas_res_region$pos)
  end <- max(ctwas_res_region$pos)
  
  ctwas_res_region <- ctwas_res_region[order(ctwas_res_region$pos),]
  ctwas_res_region_gene <- ctwas_res_region[ctwas_res_region$type=="gene",]
  ctwas_res_region_snp <- ctwas_res_region[ctwas_res_region$type=="SNP",]
  
  #region name
  print(paste0("Region: ", region_tag_plot))
  
  #table of genes in region
  print(ctwas_res_region_gene[,report_cols])
  
  par(mfrow=c(4,1))
  
  #gene z scores
  plot(ctwas_res_region_gene$pos, abs(ctwas_res_region_gene$z), xlab="Position", ylab="abs(gene_z)", xlim=c(start,end),
   ylim=c(0,max(sig_thresh, abs(ctwas_res_region_gene$z))),
   main=paste0("Region: ", region_tag_plot))
  abline(h=sig_thresh,col="red",lty=2)
  
  #significance threshold for SNPs
  alpha_snp <- 5*10^(-8)
  sig_thresh_snp <- qnorm(1-alpha_snp/2, lower=T)
  
  #snp z scores
  plot(ctwas_res_region_snp$pos, abs(ctwas_res_region_snp$z), xlab="Position", ylab="abs(snp_z)",xlim=c(start,end),
   ylim=c(0,max(sig_thresh_snp, max(abs(ctwas_res_region_snp$z)))))
  abline(h=sig_thresh_snp,col="purple",lty=2)
  
  #gene pips
  plot(ctwas_res_region_gene$pos, ctwas_res_region_gene$susie_pip, xlab="Position", ylab="Gene PIP", xlim=c(start,end), ylim=c(0,1))
  abline(h=0.8,col="blue",lty=2)
  
  #snp pips
  plot(ctwas_res_region_snp$pos, ctwas_res_region_snp$susie_pip, xlab="Position", ylab="SNP PIP", xlim=c(start,end), ylim=c(0,1))
  abline(h=0.8,col="blue",lty=2)
}
[1] "Region: 17_47"
           genename region_tag susie_pip    mu2     PVE      z
8093           FASN      17_47     0.009  16.25 4.4e-07   1.44
8807         CCDC57      17_47     0.062  34.69 6.2e-06  -2.78
5317        SLC16A3      17_47     0.004   9.85 1.0e-07  -1.15
12077     LINC01970      17_47     0.023  25.85 1.8e-06  -2.66
11951 RP13-516M14.1      17_47     0.018  23.24 1.2e-06   2.50
8580            CD7      17_47     0.004   9.59 9.9e-08   1.14
11918  RP13-20L14.1      17_47     0.002   5.29 3.5e-08   0.78
8086          HEXDC      17_47     0.003   6.19 5.3e-08   0.54
9236         OGFOD3      17_47     0.004   7.78 8.8e-08  -0.11
5323           NARF      17_47     0.008  12.85 2.9e-07   0.39
5325          FOXK2      17_47     0.018  34.75 1.9e-06  -4.00
5329         WDR45B      17_47     0.106  96.65 3.0e-05  10.53
5318         RAB40B      17_47     0.003  38.36 3.4e-07  -8.46
5322         FN3KRP      17_47     0.010 371.70 1.1e-05 -23.60
12045 RP11-388C12.5      17_47     0.003  20.47 1.8e-07   6.12
7755           FN3K      17_47     0.023 235.90 1.6e-05 -20.49
5321           TBCD      17_47     0.003 183.00 1.8e-06 -18.27
12030 RP11-497H17.1      17_47     0.290  40.79 3.4e-05   3.31
8766        B3GNTL1      17_47     0.007  25.75 5.3e-07   0.03
12014    AC144831.1      17_47     0.003  10.85 9.2e-08  -0.89

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
[1] "Region: 12_4"
          genename region_tag susie_pip    mu2     PVE      z
4041       CRACR2A       12_4         0  11.22 3.3e-09   1.11
2530        PARP11       12_4         0   5.78 9.2e-10   0.63
11823 RP11-320N7.2       12_4         0  14.52 5.4e-09   1.73
3212         CCND2       12_4         1 459.08 1.3e-03 -21.39

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
[1] "Region: 4_94"
          genename region_tag susie_pip    mu2     PVE      z
2400        INPP4B       4_94     0.000   7.74 2.9e-09   0.82
10243         GYPE       4_94     0.001 252.78 5.1e-07  20.36
11681 RP11-673E1.1       4_94     0.001 253.57 6.5e-07 -20.38
8156          GYPA       4_94     0.000 140.06 1.8e-07 -17.17
7266          HHIP       4_94     0.007  16.07 3.2e-07   3.94
7267         ABCE1       4_94     0.001  10.23 1.7e-08   0.09

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
[1] "Region: 13_61"
          genename region_tag susie_pip    mu2     PVE     z
3789       TUBGCP3      13_61     0.000   7.04 3.2e-09  0.62
12598 RP11-88E10.4      13_61     0.000   6.73 3.0e-09  0.55
669         ATP11A      13_61     0.008 313.46 7.7e-06 18.01
12510 RP11-88E10.5      13_61     0.001  26.61 4.7e-08 -4.15

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
[1] "Region: 2_27"
        genename region_tag susie_pip    mu2     PVE      z
12661  LINC01126       2_27     0.675 162.38 3.2e-04 -16.23
2977       THADA       2_27     0.001   7.15 1.6e-08  -2.12
6208     PLEKHH2       2_27     0.001   5.40 9.8e-09   0.46
11022 C1GALT1C1L       2_27     0.002  25.76 1.4e-07   3.04
4930    DYNC2LI1       2_27     0.002  17.97 9.6e-08  -2.07
5563       ABCG8       2_27     0.001   6.03 1.3e-08  -0.55
4943      LRPPRC       2_27     0.001   7.72 1.7e-08  -0.15

Version Author Date
dfd2b5f wesleycrouse 2021-09-07

SNPs with highest PIPs

#snps with PIP>0.8 or 20 highest PIPs
head(ctwas_snp_res[order(-ctwas_snp_res$susie_pip),report_cols_snps],
max(sum(ctwas_snp_res$susie_pip>0.8), 20))
                 id region_tag susie_pip       mu2     PVE      z
981       rs2799182        1_3     1.000     80.20 2.3e-04  -9.51
11587     rs2786487       1_26     1.000     48.46 1.4e-04   7.03
31923      rs599134       1_69     1.000     47.12 1.4e-04   6.81
36767     rs2779116       1_78     1.000    683.12 2.0e-03  30.86
41368     rs9425587       1_84     1.000     43.23 1.3e-04  -6.79
53450    rs79687284      1_108     1.000    139.81 4.1e-04  13.92
70672     rs1042034       2_13     1.000     38.44 1.1e-04  -5.51
71531   rs565332541       2_14     1.000    101.20 2.9e-04  15.51
72408      rs780093       2_16     1.000    159.52 4.6e-04  11.09
78734     rs2121564       2_28     1.000     74.77 2.2e-04   8.61
113830   rs71397673      2_102     1.000    498.29 1.4e-03  28.67
113838     rs853789      2_102     1.000   1007.68 2.9e-03  38.94
140772   rs56395424        3_9     1.000    106.47 3.1e-04 -13.84
140830   rs10602803        3_9     1.000     61.31 1.8e-04  11.11
172874   rs72964564       3_76     1.000    288.27 8.4e-04 -18.72
192307    rs1027498      3_115     1.000    105.87 3.1e-04   6.97
225668  rs149027545       4_59     1.000     80.05 2.3e-04   8.05
243261   rs11727331       4_94     1.000    160.87 4.7e-04 -17.08
243455   rs34149094       4_94     1.000     67.95 2.0e-04  -7.15
259233  rs766378231        5_2     1.000    101.45 2.9e-04  -1.29
259243   rs60116306        5_2     1.000    110.06 3.2e-04   4.71
264499  rs529337207       5_12     1.000     74.39 2.2e-04  -8.65
307442    rs6885822       5_93     1.000     62.77 1.8e-04   7.67
317496    rs9378483        6_7     1.000     44.27 1.3e-04   5.38
317606   rs55792466        6_7     1.000    146.33 4.3e-04 -11.10
317642   rs75465676        6_7     1.000     56.34 1.6e-04  -5.10
322198    rs2206734       6_15     1.000    127.99 3.7e-04  15.04
324094   rs75080831       6_19     1.000    176.71 5.1e-04 -20.15
324246   rs34877685       6_20     1.000    163.96 4.8e-04  -9.72
324255   rs72834643       6_20     1.000    491.20 1.4e-03 -21.07
324276  rs115740542       6_20     1.000    837.28 2.4e-03 -28.80
324742    rs6908155       6_21     1.000    368.28 1.1e-03   8.45
324848  rs535096266       6_21     1.000     88.30 2.6e-04   6.25
325118    rs3130253       6_23     1.000    134.17 3.9e-04  13.88
325261    rs6935940       6_27     1.000     87.89 2.6e-04   3.82
329159    rs1005230       6_33     1.000     54.15 1.6e-04   7.06
350567   rs62420266       6_74     1.000     39.85 1.2e-04  -5.70
358106  rs199804242       6_89     1.000   8208.19 2.4e-02   2.81
366073   rs60425481      6_104     1.000   7230.70 2.1e-02  -6.69
386398  rs142235947       7_33     1.000     34.16 9.9e-05  -5.29
425361    rs1703982       8_11     1.000    614.50 1.8e-03  -6.43
425382       rs2428       8_11     1.000    693.09 2.0e-03   6.08
425387  rs758184196       8_11     1.000    753.23 2.2e-03  -0.53
437404  rs150722768       8_36     1.000     71.74 2.1e-04 -10.55
437568   rs76508735       8_36     1.000    137.94 4.0e-04  -5.99
437581   rs10099921       8_36     1.000    254.90 7.4e-04 -18.49
437588   rs12550646       8_36     1.000    235.97 6.9e-04 -16.78
437596    rs6989331       8_36     1.000     94.36 2.7e-04  -2.86
484823   rs10545172       9_37     1.000     70.02 2.0e-04   9.11
499143   rs57248636       9_62     1.000     36.58 1.1e-04   5.52
502370  rs117561717       9_70     1.000     42.24 1.2e-04   6.47
509091   rs61848333      10_10     1.000    108.48 3.2e-04  10.75
526504  rs111333451      10_45     1.000     63.84 1.9e-04   8.10
526819    rs4745982      10_46     1.000   1273.52 3.7e-03 -56.67
526820    rs6480402      10_46     1.000   8853.47 2.6e-02 -53.18
526829   rs73267631      10_46     1.000   2069.29 6.0e-03   6.15
532810     rs478839      10_56     1.000     58.31 1.7e-04  -7.51
539218   rs12244851      10_70     1.000    679.01 2.0e-03  24.38
547356     rs234856       11_2     1.000    128.82 3.7e-04  -8.70
550405    rs4910498       11_8     1.000    300.37 8.7e-04 -13.81
562519    rs2596407      11_29     1.000     60.79 1.8e-04   8.39
566962   rs12294913      11_36     1.000     59.28 1.7e-04   7.56
569337    rs4944832      11_41     1.000     65.16 1.9e-04  -8.05
575731   rs76838754      11_52     1.000     64.61 1.9e-04  -2.44
575734   rs10830962      11_52     1.000    316.07 9.2e-04  19.78
578410   rs73001144      11_57     1.000     34.79 1.0e-04  -5.71
606211  rs150158762      12_33     1.000     77.62 2.3e-04  -9.16
606917    rs7397189      12_36     1.000     43.82 1.3e-04  -6.60
617756   rs55692966      12_56     1.000     41.07 1.2e-04  -6.27
635274     rs576674      13_10     1.000    110.89 3.2e-04 -10.47
649265    rs1327315      13_40     1.000     60.25 1.8e-04  -7.81
670804   rs72681869      14_20     1.000     48.89 1.4e-04  -7.31
683108   rs35889227      14_45     1.000     85.36 2.5e-04  -9.34
693353   rs12912777      15_13     1.000     53.34 1.5e-04   6.19
701664   rs66461959      15_31     1.000     87.76 2.5e-04   3.57
701678   rs67453880      15_31     1.000     95.39 2.8e-04   3.50
738440  rs117100864       17_5     1.000     44.12 1.3e-04  -6.61
739430   rs72829444       17_7     1.000    101.42 2.9e-04  10.35
739592   rs10468482       17_7     1.000     78.46 2.3e-04 -10.14
751949  rs117348249      17_35     1.000     40.58 1.2e-04   5.04
757343   rs58711252      17_43     1.000    150.34 4.4e-04  14.36
757346    rs3813026      17_43     1.000    176.04 5.1e-04  10.84
757347     rs417780      17_43     1.000    397.07 1.2e-03  19.21
757350   rs61740060      17_43     1.000    148.80 4.3e-04   4.80
757458   rs11658216      17_44     1.000     39.46 1.1e-04   4.87
789282   rs59616136      19_14     1.000    210.50 6.1e-04 -18.27
814166    rs6066141      20_29     1.000     69.12 2.0e-04  -8.59
817659    rs6099616      20_33     1.000     79.38 2.3e-04   8.97
827397    rs2834259      21_14     1.000     61.18 1.8e-04   7.73
831372    rs8129767      21_22     1.000     36.26 1.1e-04  -4.62
831649   rs60426421      21_23     1.000     40.90 1.2e-04  -6.28
842848   rs72660919       1_18     1.000    125.75 3.7e-04  -9.76
917145    rs1611236       6_24     1.000 112347.05 3.3e-01   8.54
936761  rs201369106       6_25     1.000   6739.02 2.0e-02   1.55
939856    rs9279507       6_26     1.000  89287.17 2.6e-01   1.84
957622  rs138917529       7_32     1.000    111.47 3.2e-04 -12.14
995050    rs3217791       12_4     1.000    103.57 3.0e-04  -9.12
1049805  rs45625038      16_25     1.000     72.36 2.1e-04   6.08
1057134  rs61745086      16_53     1.000    370.14 1.1e-03 -18.28
1057579    rs551118      16_53     1.000    700.99 2.0e-03  23.96
1083757      rs5112      19_32     1.000     87.30 2.5e-04  -8.57
1090658 rs201074739      19_35     1.000     83.64 2.4e-04  -7.84
1107866    rs855791      22_14     1.000    543.50 1.6e-03 -26.89
113831     rs537183      2_102     0.999    974.91 2.8e-03  38.61
324107    rs2281074       6_19     0.999    154.85 4.5e-04 -19.39
356962   rs10457576       6_87     0.999     35.10 1.0e-04   5.73
547354     rs234852       11_2     0.999     67.97 2.0e-04   3.51
549865    rs3750952       11_6     0.999     37.09 1.1e-04  -5.95
595881   rs66720652      12_15     0.999     35.30 1.0e-04  -5.82
625676   rs80019595      12_74     0.999     91.58 2.7e-04   3.88
660695    rs9549304      13_61     0.999     43.64 1.3e-04   7.90
661889   rs17122779       14_3     0.999     34.58 1.0e-04   5.64
713177   rs11642004       16_4     0.999     33.99 9.9e-05   5.80
742847   rs59503666      17_15     0.999     83.41 2.4e-04 -13.24
995079    rs3217860       12_4     0.999     54.78 1.6e-04   9.32
324057   rs10498727       6_19     0.998     55.36 1.6e-04   1.65
325474    rs2856992       6_27     0.998     48.33 1.4e-04  -5.62
526479  rs117731828      10_45     0.998     32.97 9.6e-05  -6.82
606244  rs112538405      12_34     0.998     34.29 9.9e-05  -5.56
661938   rs34237552       14_3     0.998     37.42 1.1e-04   5.94
752960   rs62062484      17_37     0.998     31.28 9.1e-05  -5.14
757456    rs4371218      17_44     0.998     32.67 9.5e-05  -3.36
783928     rs351988       19_2     0.998     42.20 1.2e-04  -6.40
957592    rs3757840       7_32     0.998    244.00 7.1e-04 -27.52
203108   rs34927251       4_17     0.997     32.00 9.3e-05  -5.38
359204  rs540973884       6_92     0.997     58.18 1.7e-04  -8.58
550677   rs79057673       11_8     0.997     36.94 1.1e-04   6.04
742789    rs3816511      17_15     0.997     48.32 1.4e-04  -9.10
744242    rs9891654      17_18     0.997     46.61 1.3e-04  -6.36
113886  rs112308555      2_103     0.996     28.70 8.3e-05   4.91
287801   rs17462893       5_57     0.996     35.14 1.0e-04   6.77
578486   rs11224303      11_58     0.996    253.77 7.3e-04 -15.04
610958    rs2137537      12_44     0.996     33.78 9.8e-05   5.73
359196     rs590325       6_92     0.995     31.97 9.2e-05   6.70
547134    rs3842748       11_2     0.995     89.05 2.6e-04  -8.66
625668  rs112623431      12_74     0.995     86.49 2.5e-04  -3.50
839110     rs135101      22_18     0.995     32.89 9.5e-05   3.40
195375    rs9812813      3_120     0.994     49.16 1.4e-04   7.35
325008    rs3129685       6_23     0.994     69.97 2.0e-04   6.26
784986   rs10410896       19_4     0.994     38.76 1.1e-04   6.42
1032848  rs45617834      14_52     0.994     34.76 1.0e-04  -5.61
536468    rs6584362      10_64     0.993     29.33 8.5e-05  -4.40
562064    rs2863159      11_28     0.993     39.92 1.2e-04   6.42
1025    rs113120570        1_3     0.992     76.34 2.2e-04 -11.36
534213    rs1977833      10_59     0.992    128.51 3.7e-04 -11.86
552866       rs5215      11_12     0.992     84.38 2.4e-04  -9.02
624695  rs149837779      12_73     0.991     29.83 8.6e-05   5.96
675341     rs873642      14_30     0.991     42.28 1.2e-04   8.93
172891    rs6797915       3_76     0.990     44.02 1.3e-04   8.80
317409     rs201036        6_6     0.990     30.07 8.7e-05  -5.27
633584   rs60353775       13_7     0.990    104.97 3.0e-04  11.83
733107    rs2927324      16_45     0.988     38.59 1.1e-04  -6.33
999     rs140140100        1_3     0.987     29.91 8.6e-05   1.49
323157     rs191816       6_17     0.987     33.56 9.6e-05   5.41
376826   rs13235534       7_15     0.987     31.25 9.0e-05   5.35
538670   rs11195508      10_70     0.987     34.76 1.0e-04  -5.48
575738     rs271042      11_52     0.987     41.41 1.2e-04  -2.47
873617    rs3811444      1_131     0.987     59.43 1.7e-04  10.10
327681   rs10305514       6_30     0.986     31.90 9.1e-05   5.57
107114    rs1427297       2_86     0.985     30.58 8.8e-05  -5.27
786913   rs11880903       19_7     0.985     28.23 8.1e-05   5.05
469458   rs10758593        9_4     0.984     46.39 1.3e-04   6.79
759185    rs2635417      17_47     0.984    241.53 6.9e-04  22.39
72195     rs1554481       2_15     0.983     27.00 7.7e-05   4.60
569264   rs11603349      11_41     0.981    123.16 3.5e-04 -11.10
140815     rs709149        3_9     0.980     85.30 2.4e-04 -13.67
153187   rs71623875       3_39     0.980     30.17 8.6e-05   4.93
378082    rs7778372       7_17     0.979     36.04 1.0e-04  -5.76
634521    rs9508717       13_9     0.979     38.79 1.1e-04  -5.99
784962   rs11878545       19_4     0.979     33.17 9.4e-05   5.69
458346  rs138983405       8_78     0.978     71.74 2.0e-04  -9.06
568462    rs3781660      11_39     0.978     27.06 7.7e-05  -4.85
734945   rs11641197      16_49     0.976     32.22 9.1e-05   6.79
782433     rs531621      18_45     0.976     46.13 1.3e-04   6.73
324138  rs115902543       6_20     0.975     30.27 8.6e-05  -3.87
818205    rs6026545      20_34     0.975     37.88 1.1e-04   5.83
535371   rs35909109      10_62     0.974     26.42 7.5e-05   4.76
416862   rs10227304       7_93     0.973     31.59 8.9e-05  -4.20
743536    rs2946517      17_16     0.972     49.06 1.4e-04  -8.71
670887    rs2883893      14_20     0.971     30.72 8.7e-05   4.66
173519    rs7622489       3_78     0.964     46.48 1.3e-04   6.84
675356   rs17245565      14_30     0.964     48.54 1.4e-04  -8.58
739441    rs1641549       17_7     0.964     38.17 1.1e-04   8.54
751890   rs34221578      17_34     0.964     56.66 1.6e-04   7.42
35864     rs2990245       1_76     0.963     47.78 1.3e-04   7.69
151518   rs77833543       3_33     0.963     26.41 7.4e-05   5.03
454393     rs485453       8_69     0.961     27.53 7.7e-05   5.15
395373  rs374118515       7_48     0.960     30.72 8.6e-05  -5.38
503788    rs1886296       9_73     0.959     25.64 7.1e-05  -4.47
191888    rs9880677      3_114     0.958     35.01 9.7e-05   6.12
988927  rs374499153       11_1     0.958     78.45 2.2e-04   9.65
323896   rs34706906       6_19     0.955     54.51 1.5e-04 -11.13
355584   rs41285272       6_85     0.955     26.65 7.4e-05   4.76
480557   rs34280179       9_26     0.955     29.72 8.2e-05   5.01
609395    rs2884593      12_40     0.955     30.12 8.4e-05   6.48
355109    rs1744620       6_83     0.954     24.96 6.9e-05  -4.66
598401    rs7953190      12_19     0.953     79.59 2.2e-04  -8.99
618452   rs10777868      12_58     0.953     34.91 9.7e-05  -7.00
754346    rs8070232      17_39     0.953     29.88 8.3e-05   5.35
539248   rs66808559      10_70     0.951     31.16 8.6e-05   4.52
959003   rs41295942       7_62     0.951     29.81 8.2e-05  -5.02
173458    rs1260471       3_77     0.950     48.41 1.3e-04  -7.16
503830   rs28624681       9_73     0.950    140.05 3.9e-04  12.54
839126   rs13055886      22_18     0.950     87.90 2.4e-04  -9.14
319282    rs4357124       6_11     0.949     27.45 7.6e-05   5.26
675339   rs41307086      14_29     0.949     28.29 7.8e-05   4.70
486193   rs13285167       9_40     0.948     25.00 6.9e-05   4.69
97060      rs650588       2_66     0.946     50.52 1.4e-04  -6.73
1073214  rs11672387      19_10     0.946     47.45 1.3e-04   8.27
315896     rs318468        6_3     0.945     30.65 8.4e-05   5.40
600046    rs7302975      12_21     0.942     25.59 7.0e-05  -4.71
794040   rs58526561      19_23     0.942     88.85 2.4e-04 -10.83
842910   rs61777615       1_18     0.942    109.63 3.0e-04   1.06
130076   rs13029395      2_133     0.941     26.42 7.2e-05   3.90
282389   rs13174383       5_45     0.941     54.54 1.5e-04   7.15
794347     rs889140      19_23     0.941     28.80 7.9e-05  -5.00
562279   rs75065406      11_28     0.940     27.09 7.4e-05  -5.12
819593    rs3901528      20_36     0.940     45.25 1.2e-04  -6.60
8390     rs35495299       1_19     0.939     63.21 1.7e-04  -5.95
507491    rs3824667       10_8     0.937     29.61 8.1e-05   5.17
425403   rs13265731       8_11     0.932    696.03 1.9e-03   6.18
548417   rs72883124       11_4     0.932     32.16 8.7e-05  -5.58
132524    rs7584554      2_137     0.928     39.40 1.1e-04   6.90
282667   rs12189028       5_45     0.927     31.84 8.6e-05  -2.39
151504  rs147347968       3_33     0.926     25.35 6.8e-05   4.74
156510   rs17775391       3_45     0.924     31.71 8.5e-05  -5.12
53459     rs3754140      1_108     0.923     77.67 2.1e-04 -10.21
526420   rs10998007      10_45     0.922     25.01 6.7e-05   3.88
324748    rs7775817       6_21     0.921    282.60 7.6e-04  -2.43
244102   rs10305918       4_95     0.920     25.94 6.9e-05   4.71
647365    rs9530281      13_36     0.920     24.56 6.6e-05  -4.56
187151   rs10653660      3_104     0.916    161.38 4.3e-04 -16.44
181172   rs28663084       3_94     0.915     63.08 1.7e-04  -7.84
78216   rs138452194       2_27     0.914     44.51 1.2e-04  -3.13
31045    rs72987493       1_67     0.911     37.51 9.9e-05   5.95
84331    rs11886868       2_40     0.909     33.92 9.0e-05  -5.87
660963    rs1760940       14_1     0.909     63.35 1.7e-04   7.97
36770   rs138055271       1_78     0.907     29.96 7.9e-05  -6.73
441585   rs56386732       8_45     0.907     29.93 7.9e-05   5.21
502540  rs115478735       9_70     0.907    137.05 3.6e-04  17.60
550695   rs11042847       11_8     0.905     73.04 1.9e-04   9.79
757267   rs74784618      17_43     0.905     46.85 1.2e-04   5.46
53455      rs340835      1_108     0.904     88.41 2.3e-04  12.37
737738   rs12449600       17_3     0.902     37.55 9.8e-05  -5.75
580755  rs117719056      11_62     0.901     24.05 6.3e-05  -4.22
416937    rs3793342       7_93     0.898     27.21 7.1e-05  -5.20
167086   rs62258976       3_65     0.897     23.53 6.1e-05   4.36
416944     rs743506       7_93     0.897     25.64 6.7e-05  -3.97
630122   rs10781644      12_82     0.895     28.16 7.3e-05  -5.43
306029   rs74417235       5_91     0.887     30.61 7.9e-05  -5.44
488442   rs62550974       9_45     0.887    227.54 5.9e-04 -19.55
547312     rs231842       11_2     0.885     48.49 1.2e-04   6.45
570116    rs1215071      11_42     0.885     32.29 8.3e-05   5.65
539212  rs117764423      10_70     0.884    158.79 4.1e-04  -6.70
259159    rs4956970        5_1     0.883     27.53 7.1e-05  -5.09
915619    rs2394122       6_22     0.883     89.73 2.3e-04 -12.62
728960   rs72799826      16_38     0.881     25.79 6.6e-05  -5.00
534757   rs17109928      10_60     0.878     31.44 8.0e-05   5.60
637836  rs374017936      13_16     0.878     30.18 7.7e-05   5.35
325624    rs6934244       6_27     0.877     30.57 7.8e-05   5.55
448551   rs60855359       8_58     0.877     25.11 6.4e-05  -4.59
225625    rs6532039       4_59     0.876     34.00 8.6e-05  -4.50
746857  rs118132312      17_23     0.875     24.49 6.2e-05   4.43
93135     rs4435501       2_57     0.872     30.50 7.7e-05   5.48
556773    rs4923464      11_19     0.867     28.78 7.2e-05  -5.03
57      rs201014604        1_1     0.866     24.95 6.3e-05   4.54
582715  rs139117557      11_67     0.866     23.97 6.0e-05  -4.35
509202   rs12218957      10_10     0.864     28.08 7.0e-05   4.99
1107888    rs881144      22_14     0.864     89.16 2.2e-04  14.34
151523   rs73079289       3_33     0.862     28.82 7.2e-05  -5.14
132458    rs6722529      2_137     0.861     34.00 8.5e-05  -5.83
568157   rs72932183      11_38     0.859     25.13 6.3e-05  -4.66
939845    rs3130292       6_26     0.858  89458.44 2.2e-01  14.05
123635     rs231811      2_120     0.857     25.60 6.4e-05   4.53
736439    rs8044191      16_54     0.857     34.96 8.7e-05  -6.58
604810   rs55770587      12_31     0.856     50.79 1.3e-04  -7.93
693911   rs77839142      15_14     0.854     24.89 6.2e-05   4.38
734937     rs247834      16_49     0.854     31.88 7.9e-05   6.63
529664   rs58142007      10_51     0.853     24.00 6.0e-05  -4.02
187420    rs2141746      3_105     0.850     76.73 1.9e-04  -8.38
739696  rs116982102       17_8     0.850     23.88 5.9e-05  -4.28
295993      rs11064       5_72     0.849     24.36 6.0e-05  -4.40
810545   rs61734341      20_19     0.848     27.69 6.8e-05  -5.10
144605    rs2173058       3_17     0.847     34.89 8.6e-05  -5.21
618399   rs10860185      12_58     0.843     24.48 6.0e-05  -3.68
604513   rs11168408      12_30     0.842    594.75 1.5e-03  19.93
609362     rs189339      12_40     0.841     39.53 9.7e-05  -7.92
782332   rs72973445      18_45     0.841     24.09 5.9e-05   4.26
67334    rs10167277        2_7     0.840     26.34 6.4e-05  -4.69
78165    rs57381820       2_27     0.839    172.02 4.2e-04 -16.56
975349   rs12555274       9_16     0.836    101.51 2.5e-04  10.14
612903     rs310792      12_47     0.835     25.17 6.1e-05  -4.51
872087   rs56043070      1_131     0.835     33.66 8.2e-05  -6.21
583680   rs71466797      11_70     0.829     28.67 6.9e-05  -4.16
362646    rs6921399       6_98     0.827     25.45 6.1e-05   4.46
319034   rs12663475       6_10     0.825     26.28 6.3e-05  -4.74
187421   rs11924635      3_105     0.823     29.24 7.0e-05   1.37
458694   rs28529793       8_78     0.822    101.11 2.4e-04  -7.87
244784   rs59435073       4_97     0.820     24.45 5.8e-05  -4.32
746436   rs12938438      17_22     0.820     25.12 6.0e-05   4.20
327810    rs6904583       6_31     0.819     25.77 6.1e-05   4.72
721939   rs58200984      16_24     0.819     25.51 6.1e-05   4.80
256862   rs62336098      4_119     0.818     25.93 6.2e-05  -4.47
566335     rs174548      11_34     0.817     98.02 2.3e-04  -9.84
85910   rs369551671       2_43     0.813     24.03 5.7e-05  -4.30
659449     rs754205      13_59     0.813     27.15 6.4e-05  -4.59
151864    rs6446297       3_35     0.807     81.42 1.9e-04   9.01
84320    rs11884411       2_40     0.806     44.45 1.0e-04  -7.27
380914    rs4552808       7_23     0.803     27.42 6.4e-05  -4.66
1024449   rs7329468      13_62     0.803     92.21 2.2e-04 -13.49
111645     rs270920       2_96     0.802     30.18 7.0e-05  -5.47
957448    rs2971681       7_32     0.802     74.48 1.7e-04  11.01

SNPs with largest effect sizes

#plot PIP vs effect size
plot(ctwas_snp_res$susie_pip, ctwas_snp_res$mu2, xlab="PIP", ylab="mu^2", main="SNP PIPs vs Effect Size")

Version Author Date
dfd2b5f wesleycrouse 2021-09-07
#SNPs with 50 largest effect sizes
head(ctwas_snp_res[order(-ctwas_snp_res$mu2),report_cols_snps],50)
                id region_tag susie_pip      mu2     PVE    z
917145   rs1611236       6_24     1.000 112347.1 3.3e-01 8.54
917127 rs111734624       6_24     0.278 112088.1 9.1e-02 8.55
917124   rs2508055       6_24     0.278 112088.1 9.1e-02 8.55
917172   rs1611252       6_24     0.234 112087.9 7.6e-02 8.55
917189   rs1611260       6_24     0.216 112087.5 7.0e-02 8.55
917168   rs1611248       6_24     0.197 112087.4 6.4e-02 8.55
917195   rs1611265       6_24     0.204 112087.3 6.6e-02 8.55
917063   rs1633033       6_24     0.171 112086.1 5.6e-02 8.56
917199   rs2394171       6_24     0.109 112085.6 3.5e-02 8.55
917197   rs1611267       6_24     0.080 112085.3 2.6e-02 8.55
917120   rs1737020       6_24     0.106 112085.3 3.5e-02 8.55
917121   rs1737019       6_24     0.106 112085.3 3.5e-02 8.55
917201   rs2893981       6_24     0.097 112085.3 3.2e-02 8.55
917131   rs1611228       6_24     0.084 112085.1 2.7e-02 8.55
917076   rs2844838       6_24     0.095 112084.8 3.1e-02 8.55
917080   rs1633032       6_24     0.294 112079.1 9.6e-02 8.57
917114   rs1633020       6_24     0.013 112071.1 4.1e-03 8.54
917118   rs1633018       6_24     0.010 112070.2 3.1e-03 8.54
917143   rs1611234       6_24     0.002 112062.6 5.9e-04 8.53
917003   rs1610726       6_24     0.201 112060.8 6.6e-02 8.58
917071   rs2844840       6_24     0.008 112046.8 2.6e-03 8.55
917398   rs3129185       6_24     0.000 112040.0 4.1e-05 8.53
917413   rs1736999       6_24     0.000 112034.0 2.0e-06 8.51
917166   rs1611246       6_24     0.000 112025.3 7.4e-05 8.53
917426   rs1633001       6_24     0.000 112024.8 1.5e-06 8.51
917602   rs1632980       6_24     0.000 112018.3 2.0e-06 8.51
917099   rs1614309       6_24     0.000 111993.0 2.0e-05 8.55
917098   rs1633030       6_24     0.000 111902.0 2.4e-08 8.54
917211   rs9258382       6_24     0.000 111788.0 2.2e-07 8.63
917208   rs9258379       6_24     0.000 111602.5 8.3e-16 8.60
917157   rs1611241       6_24     0.000 111471.4 8.3e-16 8.65
917102   rs1633028       6_24     0.000 111314.1 0.0e+00 8.55
917160   rs1611244       6_24     0.000 110894.7 0.0e+00 8.66
917115   rs2735042       6_24     0.000 110713.3 0.0e+00 8.36
917196   rs1611266       6_24     0.000 109890.7 0.0e+00 8.83
917169   rs1611249       6_24     0.000 109408.4 0.0e+00 8.81
917135   rs1611230       6_24     0.000 109141.0 0.0e+00 8.82
917184 rs145043018       6_24     0.000 109117.9 0.0e+00 8.82
917194 rs147376303       6_24     0.000 109117.3 0.0e+00 8.82
917205   rs9258376       6_24     0.000 109115.9 0.0e+00 8.82
917212   rs1633016       6_24     0.000 109114.5 0.0e+00 8.82
917057   rs1633035       6_24     0.000 109112.3 0.0e+00 8.81
917090   rs1618670       6_24     0.000 109105.4 0.0e+00 8.82
917265   rs1633014       6_24     0.000 109103.6 0.0e+00 8.81
917117   rs1633019       6_24     0.000 109096.6 0.0e+00 8.80
917379   rs1633010       6_24     0.000 109066.3 0.0e+00 8.79
917503    rs909722       6_24     0.000 109047.9 0.0e+00 8.77
917535   rs1610713       6_24     0.000 109046.6 0.0e+00 8.77
917460   rs1736991       6_24     0.000 109045.5 0.0e+00 8.76
917515   rs1610648       6_24     0.000 109039.0 0.0e+00 8.76

SNPs with highest PVE

#SNPs with 50 highest pve
head(ctwas_snp_res[order(-ctwas_snp_res$PVE),report_cols_snps],50)
                 id region_tag susie_pip       mu2    PVE      z
917145    rs1611236       6_24     1.000 112347.05 0.3300   8.54
939856    rs9279507       6_26     1.000  89287.17 0.2600   1.84
939845    rs3130292       6_26     0.858  89458.44 0.2200  14.05
939842    rs3130291       6_26     0.606  89457.62 0.1600  14.05
917080    rs1633032       6_24     0.294 112079.14 0.0960   8.57
917124    rs2508055       6_24     0.278 112088.10 0.0910   8.55
917127  rs111734624       6_24     0.278 112088.11 0.0910   8.55
917172    rs1611252       6_24     0.234 112087.88 0.0760   8.55
917189    rs1611260       6_24     0.216 112087.46 0.0700   8.55
917003    rs1610726       6_24     0.201 112060.80 0.0660   8.58
917195    rs1611265       6_24     0.204 112087.32 0.0660   8.55
917168    rs1611248       6_24     0.197 112087.44 0.0640   8.55
917063    rs1633033       6_24     0.171 112086.10 0.0560   8.56
917120    rs1737020       6_24     0.106 112085.29 0.0350   8.55
917121    rs1737019       6_24     0.106 112085.29 0.0350   8.55
917199    rs2394171       6_24     0.109 112085.59 0.0350   8.55
917201    rs2893981       6_24     0.097 112085.27 0.0320   8.55
917076    rs2844838       6_24     0.095 112084.84 0.0310   8.55
917131    rs1611228       6_24     0.084 112085.10 0.0270   8.55
526820    rs6480402      10_46     1.000   8853.47 0.0260 -53.18
917197    rs1611267       6_24     0.080 112085.33 0.0260   8.55
358106  rs199804242       6_89     1.000   8208.19 0.0240   2.81
366073   rs60425481      6_104     1.000   7230.70 0.0210  -6.69
936761  rs201369106       6_25     1.000   6739.02 0.0200   1.55
358122    rs6923513       6_89     0.624   8246.99 0.0150   2.89
366069    rs3106169      6_104     0.598   7192.50 0.0130   2.33
936771   rs34259803       6_25     0.623   6751.83 0.0120   6.25
366078    rs3106167      6_104     0.454   7192.39 0.0095   2.33
358105    rs2327654       6_89     0.376   8246.42 0.0090   2.89
526828   rs79086908      10_46     0.547   5256.77 0.0084  11.40
366070    rs3127598      6_104     0.367   7192.34 0.0077   2.34
526825   rs35233497      10_46     0.453   5256.31 0.0069  11.40
526829   rs73267631      10_46     1.000   2069.29 0.0060   6.15
366062   rs11755965      6_104     0.269   7190.46 0.0056   2.34
936759    rs3869131       6_25     0.251   6751.68 0.0049   6.23
917114    rs1633020       6_24     0.013 112071.13 0.0041   8.54
526819    rs4745982      10_46     1.000   1273.52 0.0037 -56.67
917118    rs1633018       6_24     0.010 112070.22 0.0031   8.54
113838     rs853789      2_102     1.000   1007.68 0.0029  38.94
113831     rs537183      2_102     0.999    974.91 0.0028  38.61
917071    rs2844840       6_24     0.008 112046.78 0.0026   8.55
324276  rs115740542       6_20     1.000    837.28 0.0024 -28.80
939824    rs3132935       6_26     0.009  89437.63 0.0024  14.03
425387  rs758184196       8_11     1.000    753.23 0.0022  -0.53
36767     rs2779116       1_78     1.000    683.12 0.0020  30.86
425382       rs2428       8_11     1.000    693.09 0.0020   6.08
539218   rs12244851      10_70     1.000    679.01 0.0020  24.38
1057579    rs551118      16_53     1.000    700.99 0.0020  23.96
425403   rs13265731       8_11     0.932    696.03 0.0019   6.18
425361    rs1703982       8_11     1.000    614.50 0.0018  -6.43

SNPs with largest z scores

#SNPs with 50 largest z scores
head(ctwas_snp_res[order(-abs(ctwas_snp_res$z)),report_cols_snps],50)
                 id region_tag susie_pip     mu2     PVE      z
526819    rs4745982      10_46     1.000 1273.52 3.7e-03 -56.67
526820    rs6480402      10_46     1.000 8853.47 2.6e-02 -53.18
526816    rs6480398      10_46     0.000  852.79 0.0e+00  46.60
113838     rs853789      2_102     1.000 1007.68 2.9e-03  38.94
113831     rs537183      2_102     0.999  974.91 2.8e-03  38.61
113832     rs518598      2_102     0.001  957.10 4.1e-06  38.19
113834     rs485094      2_102     0.000  908.39 4.4e-10  37.34
957635    rs1004558       7_32     0.345  714.20 7.2e-04  35.99
957634    rs1985469       7_32     0.239  713.12 4.9e-04  35.98
957586    rs1799884       7_32     0.097  711.29 2.0e-04  35.94
957607     rs741037       7_32     0.068  709.95 1.4e-04  35.93
957576    rs2971670       7_32     0.057  709.70 1.2e-04  35.92
957568    rs2908289       7_32     0.046  709.41 9.4e-05  35.91
957567     rs730497       7_32     0.056  710.63 1.2e-04  35.89
957629   rs12056308       7_32     0.020  706.21 4.1e-05  35.89
957617    rs2908286       7_32     0.023  706.63 4.8e-05  35.88
957644    rs2971668       7_32     0.025  707.41 5.1e-05  35.88
957661    rs2908282       7_32     0.006  702.93 1.3e-05  35.83
957600    rs6975024       7_32     0.010  705.72 2.0e-05  35.82
957648    rs2971667       7_32     0.004  702.70 9.1e-06  35.82
957650     rs917793       7_32     0.004  702.31 8.6e-06  35.81
957621    rs4607517       7_32     0.001  696.76 1.2e-06  35.72
957699     rs732360       7_32     0.000  659.82 5.2e-13  35.03
957599    rs2971669       7_32     0.000  662.14 1.7e-11  34.38
957707    rs2075066       7_32     0.000  628.68 2.0e-13  34.24
957680     rs878521       7_32     0.000  556.99 3.4e-11  32.15
36767     rs2779116       1_78     1.000  683.12 2.0e-03  30.86
113836    rs2544360      2_102     0.000  778.86 5.6e-10  30.12
113837     rs853791      2_102     0.000  772.11 5.1e-10  29.94
526841  rs142196758      10_46     0.000  812.22 0.0e+00 -29.25
324276  rs115740542       6_20     1.000  837.28 2.4e-03 -28.80
36779      rs863327       1_78     0.003  584.76 5.1e-06  28.76
113830   rs71397673      2_102     1.000  498.29 1.4e-03  28.67
113840     rs853785      2_102     0.162  699.49 3.3e-04  28.45
113839     rs860510      2_102     0.397  687.42 7.9e-04  28.07
113833     rs579275      2_102     0.441  674.85 8.6e-04  27.85
957517    rs2908292       7_32     0.462  247.20 3.3e-04  27.62
957518    rs2971671       7_32     0.333  245.38 2.4e-04  27.58
36747    rs12042917       1_78     0.002  534.14 3.3e-06  27.53
957592    rs3757840       7_32     0.998  244.00 7.1e-04 -27.52
957550   rs10259649       7_32     0.040  237.51 2.7e-05  27.49
957515    rs2908293       7_32     0.126  240.77 8.8e-05  27.48
36739    rs12405509       1_78     0.002  530.53 3.2e-06  27.45
957549    rs2300584       7_32     0.032  235.42 2.2e-05  27.41
957500    rs2908294       7_32     0.008  226.93 5.4e-06  27.14
759179    rs2256833      17_47     0.762  505.50 1.1e-03 -27.01
36705    rs11264980       1_78     0.002  510.91 2.6e-06  26.99
759180    rs2459703      17_47     0.239  502.76 3.5e-04 -26.96
1107866    rs855791      22_14     1.000  543.50 1.6e-03 -26.89
957686   rs13229610       7_32     0.002  221.74 1.1e-06 -26.46

Gene set enrichment for genes with PIP>0.8

#GO enrichment analysis
library(enrichR)
Welcome to enrichR
Checking connection ... 
Enrichr ... Connection is Live!
FlyEnrichr ... Connection is available!
WormEnrichr ... Connection is available!
YeastEnrichr ... Connection is available!
FishEnrichr ... Connection is available!
dbs <- c("GO_Biological_Process_2021", "GO_Cellular_Component_2021", "GO_Molecular_Function_2021")
genes <- ctwas_gene_res$genename[ctwas_gene_res$susie_pip>0.8]

#number of genes for gene set enrichment
length(genes)
[1] 29
if (length(genes)>0){
  GO_enrichment <- enrichr(genes, dbs)

  for (db in dbs){
    print(db)
    df <- GO_enrichment[[db]]
    df <- df[df$Adjusted.P.value<0.05,c("Term", "Overlap", "Adjusted.P.value", "Genes")]
    print(df)
  }
  
  #DisGeNET enrichment
  
  # devtools::install_bitbucket("ibi_group/disgenet2r")
  library(disgenet2r)
  
  disgenet_api_key <- get_disgenet_api_key(
                    email = "wesleycrouse@gmail.com", 
                    password = "uchicago1" )
  
  Sys.setenv(DISGENET_API_KEY= disgenet_api_key)
  
  res_enrich <-disease_enrichment(entities=genes, vocabulary = "HGNC",
                               database = "CURATED" )
  
  df <- res_enrich@qresult[1:10, c("Description", "FDR", "Ratio",  "BgRatio")]
  print(df)
  
  #WebGestalt enrichment
  library(WebGestaltR)
  
  background <- ctwas_gene_res$genename
  
  #listGeneSet()
  databases <- c("pathway_KEGG", "disease_GLAD4U", "disease_OMIM")
  
  enrichResult <- WebGestaltR(enrichMethod="ORA", organism="hsapiens",
                              interestGene=genes, referenceGene=background,
                              enrichDatabase=databases, interestGeneType="genesymbol",
                              referenceGeneType="genesymbol", isOutput=F)
  print(enrichResult[,c("description", "size", "overlap", "FDR", "database", "userId")])
}
Uploading data to Enrichr... Done.
  Querying GO_Biological_Process_2021... Done.
  Querying GO_Cellular_Component_2021... Done.
  Querying GO_Molecular_Function_2021... Done.
Parsing results... Done.
[1] "GO_Biological_Process_2021"
[1] Term             Overlap          Adjusted.P.value Genes           
<0 rows> (or 0-length row.names)
[1] "GO_Cellular_Component_2021"
[1] Term             Overlap          Adjusted.P.value Genes           
<0 rows> (or 0-length row.names)
[1] "GO_Molecular_Function_2021"
[1] Term             Overlap          Adjusted.P.value Genes           
<0 rows> (or 0-length row.names)
SMIM19 gene(s) from the input list not found in DisGeNET CURATEDITGAD gene(s) from the input list not found in DisGeNET CURATEDARFIP1 gene(s) from the input list not found in DisGeNET CURATEDCNIH4 gene(s) from the input list not found in DisGeNET CURATEDTRIM58 gene(s) from the input list not found in DisGeNET CURATEDSEC14L4 gene(s) from the input list not found in DisGeNET CURATEDNUDT4 gene(s) from the input list not found in DisGeNET CURATEDHLX gene(s) from the input list not found in DisGeNET CURATED
                                                           Description
44                                                     Opisthorchiasis
86                                           Glutaric aciduria, type 1
88                                     Opisthorchis felineus Infection
89                                    Opisthorchis viverrini Infection
136                                            RETINITIS PIGMENTOSA 42
143 MEGALENCEPHALY-POLYMICROGYRIA-POLYDACTYLY-HYDROCEPHALUS SYNDROME 3
147                          CRISPONI/COLD-INDUCED SWEATING SYNDROME 3
149                             Paroxysmal Nonkinesigenic Dyskinesia 1
62                              Iron-Refractory Iron Deficiency Anemia
75                                               Carcinoma, Large Cell
           FDR Ratio BgRatio
44  0.04112554  1/21  1/9703
86  0.04112554  1/21  1/9703
88  0.04112554  1/21  1/9703
89  0.04112554  1/21  1/9703
136 0.04112554  1/21  1/9703
143 0.04112554  1/21  1/9703
147 0.04112554  1/21  1/9703
149 0.04112554  1/21  1/9703
62  0.04924897  1/21  3/9703
75  0.04924897  1/21  2/9703
******************************************

*                                        *

*          Welcome to WebGestaltR !      *

*                                        *

******************************************
Loading the functional categories...
Loading the ID list...
Loading the reference list...
Performing the enrichment analysis...
Warning in oraEnrichment(interestGeneList, referenceGeneList, geneSet,
minNum = minNum, : No significant gene set is identified based on FDR 0.05!
NULL

sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Scientific Linux 7.4 (Nitrogen)

Matrix products: default
BLAS/LAPACK: /software/openblas-0.2.19-el7-x86_64/lib/libopenblas_haswellp-r0.2.19.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] WebGestaltR_0.4.4 disgenet2r_0.99.2 enrichR_3.0       cowplot_1.0.0    
[5] ggplot2_3.3.3    

loaded via a namespace (and not attached):
  [1] bitops_1.0-6                matrixStats_0.57.0         
  [3] fs_1.3.1                    bit64_4.0.5                
  [5] doParallel_1.0.16           progress_1.2.2             
  [7] httr_1.4.1                  rprojroot_2.0.2            
  [9] GenomeInfoDb_1.20.0         doRNG_1.8.2                
 [11] tools_3.6.1                 utf8_1.2.1                 
 [13] R6_2.5.0                    DBI_1.1.1                  
 [15] BiocGenerics_0.30.0         colorspace_1.4-1           
 [17] withr_2.4.1                 tidyselect_1.1.0           
 [19] prettyunits_1.0.2           bit_4.0.4                  
 [21] curl_3.3                    compiler_3.6.1             
 [23] git2r_0.26.1                Biobase_2.44.0             
 [25] DelayedArray_0.10.0         rtracklayer_1.44.0         
 [27] labeling_0.3                scales_1.1.0               
 [29] readr_1.4.0                 apcluster_1.4.8            
 [31] stringr_1.4.0               digest_0.6.20              
 [33] Rsamtools_2.0.0             svglite_1.2.2              
 [35] rmarkdown_1.13              XVector_0.24.0             
 [37] pkgconfig_2.0.3             htmltools_0.3.6            
 [39] fastmap_1.1.0               BSgenome_1.52.0            
 [41] rlang_0.4.11                RSQLite_2.2.7              
 [43] generics_0.0.2              farver_2.1.0               
 [45] jsonlite_1.6                BiocParallel_1.18.0        
 [47] dplyr_1.0.7                 VariantAnnotation_1.30.1   
 [49] RCurl_1.98-1.1              magrittr_2.0.1             
 [51] GenomeInfoDbData_1.2.1      Matrix_1.2-18              
 [53] Rcpp_1.0.6                  munsell_0.5.0              
 [55] S4Vectors_0.22.1            fansi_0.5.0                
 [57] gdtools_0.1.9               lifecycle_1.0.0            
 [59] stringi_1.4.3               whisker_0.3-2              
 [61] yaml_2.2.0                  SummarizedExperiment_1.14.1
 [63] zlibbioc_1.30.0             plyr_1.8.4                 
 [65] grid_3.6.1                  blob_1.2.1                 
 [67] parallel_3.6.1              promises_1.0.1             
 [69] crayon_1.4.1                lattice_0.20-38            
 [71] Biostrings_2.52.0           GenomicFeatures_1.36.3     
 [73] hms_1.1.0                   knitr_1.23                 
 [75] pillar_1.6.1                igraph_1.2.4.1             
 [77] GenomicRanges_1.36.0        rjson_0.2.20               
 [79] rngtools_1.5                codetools_0.2-16           
 [81] reshape2_1.4.3              biomaRt_2.40.1             
 [83] stats4_3.6.1                XML_3.98-1.20              
 [85] glue_1.4.2                  evaluate_0.14              
 [87] data.table_1.14.0           foreach_1.5.1              
 [89] vctrs_0.3.8                 httpuv_1.5.1               
 [91] gtable_0.3.0                purrr_0.3.4                
 [93] assertthat_0.2.1            cachem_1.0.5               
 [95] xfun_0.8                    later_0.8.0                
 [97] tibble_3.1.2                iterators_1.0.13           
 [99] GenomicAlignments_1.20.1    AnnotationDbi_1.46.0       
[101] memoise_2.0.0               IRanges_2.18.1             
[103] workflowr_1.6.2             ellipsis_0.3.2