Skip to content

karbalaei/QTL-mapping

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 

Repository files navigation

qtl mapping

1. Tensorqtl

Tensorqtl algorithm applied on both 21 different cell types and seven different broad cell types resulted from snRNA-seq data.

Flowchart

1.1. Preparing TSS file:

In Python, using recommended function from Tensorqtl tutorial (pyqtl), the TSS file was created which containing chr, start, end and gene_id.

TSS file

1.2. Preparing BED and Covariate files in R

Using the TSS file, Raw and normalized data of snRNA-Seq, the BED files and the Covariate files were created in R. Briefly speaking, I used metadata from the raw file of snRNA-Seq data and merged it with the TSS file. Then, after loading normalized data, I created the sorted BED file. For the covariate file, I used num.sv from SVA package to calculate how many PCA should I include in my analysis, which for 21 cell types it ranges from 15 to 20.

Here is an example of covariate file from astro cell type : Covariate_file

and Here is an example of BED file from astro cell type : BED_file

1.3. Runnig Tensorqtl in BASH

Using a for loop, I run Tensorqtl with three different parameters :

  1. Default parameters :

for f in ./*/*bed.gz
do
echo "Start analyses of $f"
python3 -m tensorqtl "MDD_control_sc_maf1"
$f
${f/_df.bed.gz/}
--covariates ${f/df.bed.gz/covariates.txt}
--mode cis_nominal
done

  1. Add a window of 500,000 instead of a defalut value(1Mbp).

for f in ./*/*bed.gz
do
echo "Start analyses of $f"
python3 -m tensorqtl "MDD_control_sc_maf1"
$f
${f/_df.bed.gz/_modified}
--covariates ${f/df.bed.gz/covariates.txt}
--mode cis_nominal --window=500000
done

  1. Add a maf=0.05 instead of a defalut value(0).

for f in ./*/*bed.gz
do
echo "Start analyses of $f"
python3 -m tensorqtl "MDD_control_sc_maf1"
$f
${f/_df.bed.gz/_modified_maf}
--covariates ${f/df.bed.gz/covariates.txt}
--mode cis_nominal --window=500000 --maf_threshold=0.05
done

1.4. Loading Parquet file and applying p-value correction :

In the final step, Parquet files from different analyses were loaded in R and after calculation FDR, SNPs with FDR < 0.05 were selected for further investigation.

2. Matrix eQTL

Matrix eQTL algorithm applied on both 21 different cell types and seven different broad cell types resulted from snRNA-seq data.

Flowchart

About

Results of tensorqtl analysis on snRNA-seq data

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published