An R Package for Causal Mediation Analysis of ROSMAP Data
GeneticMediation
was created as part of the UNC Wu
Lab project Constructing Causal
Mediation Pathways For Multi-Level Genomic Data
GeneticMediation
provides methods for cleaning and processing data
from the ROSMAP study and preparing it for causal mediation analysis.
The documentation pdf can be viewed
here
You can install GeneticMediation
from GitHub
with:
# install.packages("devtools")
devtools::install_github("tydarnell/GeneticMediation")
####################################################################################
#
# Software:--------------------------------------------------------
#
# R version >= 3.6.1
# devtools (to install GeneticMediation package from github)
# Rstudio (highly recommended)
#
# Data:------------------------------------------------------------
#
# ROSMAP Study:**************************************************
# ReadCounts.csv
# H3K9acDomains.csv
#
# UNC Wu Lab:****************************************************
# snps.txt
# JulyselGeneBySNP.1030.RData
# mediator_chr#_new.RData (each chr has a separate RData file)
#
####################################################################################
The ROSMAP data can be obtained from
Synapse. Read
instructions for data
access
The UNC Wu Lab data requires
permission from Dr. Di Wu
1) Create an Rproject in Rstudio
2) Install and load GeneticMediation
from
GitHub with:
# devtools::install_github("tydarnell/GeneticMediation")
library(GeneticMediation)
3) Create subdirectories of your Rproject directory: data,
data/mediator, results with:
GeneticMediation::setup_folders()
4) Put all data except for the mediator_chr#_new.RData
files in the
data folder
5) Put the mediator_chr#_new.RData
files in the mediator folder
6) Check that data files are in the data folder with:
GeneticMediation::check_data()