This page is outdated, please also see the man page.

How to run Regulatory Trait Cconcordance (RTC)?

RTC is XXX. To illustrate this, first download the example data below and go through the two steps; 1. permutation pass and 2. run RTC.


Step1: Run the permutation pass

This can be done quickly using 4 threads as follows:

for j in $(seq 1 16); do
  echo "cis --vcf genotypes.chr22.vcf.gz --bed genes.50percent.chr22.bed.gz --cov genes.covariates.pc50.txt.gz --permute 200 --chunk $j 16 --out permutations_$j\_16.txt";
done | xargs -P4 -n14 QTLtools

Then, cat all chunks together and run FDR correction:

cat permutations_*.txt | gzip -c > permutations_all.txt.gz
Rscript ./script/runFDR_cis.R permutations_all.txt.gz 0.05 permutations_all

From this, you get all your significant hits in permutations_all.significant.txt and you're ready to go to the next step.


Required files for RTC

For this step, you actually need two additionnal files:

The two files look like this:

head hotspots_b37_hg19.bed
1 1020078 1031078 11000
1 1872839 1881839 9000
1 2031839 2035839 4000
1 2141839 2147839 6000
1 2214839 2221839 7000
1 2299839 2303839 4000
1 2322839 2326839 4000
1 2338839 2357839 19000
1 2362839 2369839 7000
1 2403839 2408839 5000

Columns here correspond to (only the first three columns are used):

head GWAS.b37.txt
1_1005806 Body
1_1079198 Other
1_1247494 Digestive
1_1723031 Body
1_2069172 Body
1_2069681 Biological
1_2205581 Other
1_2387101 Neurological
1_2392648 Other
1_2452979 Other

Columns here correspond to (only the first column is used):


Step2: Run RTC

To run RTC on all the files presented so far, use:

QTLtools rtc --vcf genotypes.chr22.vcf.gz --bed genes.50percent.chr22.bed.gz --cov genes.covariates.pc50.txt.gz --hotspot hotspots_b37_hg19.bed --gwas-cis GWAS.b37.txt permutations_all.significant.txt --normal --out rtc_results.txt

This step can be tuned using the following options:

This command produces the output file rtc_results.txt:

head rtc_results.txt
22_17597462 22_17620429 ENSG00000069998.8 ENSG00000069998.8 chr22 17597462 0 chr22 17620429 0 chr22 17646177 22967 48715 64959 64959 17583447 17666446 300 0.993333 NA 0.285641
22_17597462 22_17587975 ENSG00000183307.3 ENSG00000183307.3 chr22 17597462 0 chr22 17587975 0 chr22 17602257 9487 4795 64959 64959 17583447 17666446 300 0.12 NA 0.0423723
22_18283247 22_18261544 ENSG00000269220.1 ENSG00000269220.1 chr22 18283247 0 chr22 18261544 0 chr22 18260088 21703 23159 64978 64978 18251447 18283446 48 0.395833 NA 0.00236583
22_18439958 22_18483388 ENSG00000093100.13 ENSG00000093100.13 chr22 18439958 0 chr22 18483388 0 chr22 18294263 43430 145695 64987 64987 18382447 18485446 325 0.483077 NA 0.236648
22_18448113 22_18483388 ENSG00000093100.13 ENSG00000093100.13 chr22 18448113 0 chr22 18483388 0 chr22 18294263 35275 153850 64987 64987 18382447 18485446 325 0.483077 NA 0.236648
22_18439958 22_18483388 ENSG00000243156.3 ENSG00000243156.3 chr22 18439958 0 chr22 18483388 0 chr22 18507325 43430 67367 64987 64987 18382447 18485446 325 0.483077 NA 0.236648
22_18448113 22_18483388 ENSG00000243156.3 ENSG00000243156.3 chr22 18448113 0 chr22 18483388 0 chr22 18507325 35275 59212 64987 64987 18382447 18485446 325 0.483077 NA 0.236648
22_19154522 22_19166680 ENSG00000100075.5 ENSG00000100075.5 chr22 19154522 0 chr22 19166680 0 chr22 19166343 12158 11821 65005 65005 19147447 19274446 277 0.920578 NA 0.887379
22_19156117 22_19166680 ENSG00000100075.5 ENSG00000100075.5 chr22 19156117 0 chr22 19166680 0 chr22 19166343 10563 10226 65005 65005 19147447 19274446 277 0.906137 NA 0.745216

Description of the columns in the output file:

Monday 11th July 2016