Changes

From Genome Analysis Wiki
Jump to navigationJump to search
5,087 bytes added ,  10:05, 2 February 2017
Line 19: Line 19:  
For external users, follow the instruction at [[EPACTS]] page, summarized below.  
 
For external users, follow the instruction at [[EPACTS]] page, summarized below.  
   −
*Download EPACTS binary at http://www.sph.umich.edu/csg/kang/epacts/download/epacts_v2.12.noref_binary.2012_10_01.tar.gz (101MB)
+
*Please download the latest version of EPACTS here:  http://csg.sph.umich.edu//kang/epacts/download/
*Uncompress EPACTS package to the directory you would like to install
+
*Uncompress EPACTS package to the directory you would like to install and then type the following commands
   −
  tar xzvf epacts_v2.12.noref_binary.2012_10_01.tar.gz
+
>  tar xzvf EPACTS-3.0.0.tar.gz
 +
> cd EPACTS-3.0.0
 +
> ./configure --prefix [INSTALL DIRECTORY]
 +
> make
 +
> make install
 +
   −
*Download the reference FASTA files from 1000 Genomes FTP automatically by running the following commands<br>
  −
<pre>cd epacts2.1/
  −
./ref_download.sh
  −
(For advanced users, to save time for downloading the FASTA files (~900MB), you may copy a local copy of GRCh37 FASTA file and the index file to ${EPACTS_DIR}/ext/ref/)
  −
</pre>
   
*Perform a test run by running the following command
 
*Perform a test run by running the following command
   −
  example/test_run_epacts.sh
+
EPACTS-3.0.0/example/test_run_epacts.sh
    
=== For Local Users in CSG  ===
 
=== For Local Users in CSG  ===
Line 40: Line 40:     
Once installed, test out the software by running a quick example using the test data provided in the "example" directory. The example VCF and PED files are:  
 
Once installed, test out the software by running a quick example using the test data provided in the "example" directory. The example VCF and PED files are:  
<pre>$ epacts2.1/example/1000G_exome_chr20_example_softFiltered.calls.vcf.gz
+
<pre>$ EPACTS-3.0.0/example/1000G_exome_chr20_example_softFiltered.calls.vcf.gz
   −
$ epacts2.1/example/1000G_dummy_pheno.ped
+
$ EPACTS-3.0.0/example/1000G_dummy_pheno.ped
 
</pre>  
 
</pre>  
 
<br> Run the single variant score test on the example data using this command:  
 
<br> Run the single variant score test on the example data using this command:  
<pre>$ epacts2.1/epacts single  
+
<pre>$ EPACTS-3.0.0/epacts single  
 
--vcf epacts2.1/example/1000G_exome_chr20_example_softFiltered.calls.vcf.gz  
 
--vcf epacts2.1/example/1000G_exome_chr20_example_softFiltered.calls.vcf.gz  
 
--ped epacts2.1/example/1000G_dummy_pheno.ped  
 
--ped epacts2.1/example/1000G_dummy_pheno.ped  
Line 57: Line 57:  
== 2. &nbsp;Prepare VCF file with genotypes / dosages  ==
 
== 2. &nbsp;Prepare VCF file with genotypes / dosages  ==
   −
EPACTS requires input genotype / doseage information in VCF format. &nbsp;From minimac or Impute2, you wil start with your imputed dosage file.  
+
EPACTS requires input genotype / dosage information in VCF format. &nbsp;From minimac or Impute2, you wil start with your imputed dosage file.  
    
=== A. &nbsp;Convert dosage file into VCF format  ===
 
=== A. &nbsp;Convert dosage file into VCF format  ===
   −
Use the wrapper program "dose2vcf" to convert your doseage output to VCF format. &nbsp;Download the tool from [http://www.sph.umich.edu/csg/cfuchsb/dose2vcf_v0.4.tgz here]. If you used rs numbers during imputation, you can find mapping tables here  
+
Use the wrapper program "dose2vcf" to convert your doseage output to pseudo VCF format. &nbsp;Download the tool from [http://csg.sph.umich.edu//cfuchsb/dose2vcf_v0.5.gz here]. If you used rs numbers during imputation, you can find mapping tables ready for dose2vcf [http://csg.sph.umich.edu//cfuchsb/mapping_rs_ALL.GIANT.phase1_release_v3.20101123.tgz here (214 Mb) ]
 
      +
<br>
    
To run the wrapper program, use the following command  
 
To run the wrapper program, use the following command  
Line 131: Line 131:  
<pre>A DISEASE
 
<pre>A DISEASE
 
T QT
 
T QT
C AGE</pre>
+
C AGE</pre>  
Key: &nbsp;A =&nbsp;binary trait; T = quantitative trait; C = covariate<br>
+
Key: &nbsp;A =&nbsp;binary trait; T = quantitative trait; C = covariate<br>  
    
== 4. &nbsp;Run EPACTS association pipeline  ==
 
== 4. &nbsp;Run EPACTS association pipeline  ==
    
For detailed description of options, use:  
 
For detailed description of options, use:  
<pre>epacts2.1/epacts single -man
+
<pre>EPACTS-3.0.0/epacts single -man
 
</pre>  
 
</pre>  
<br>
+
<br>  
   −
=== Primary analyses  ===
+
=== Primary analyses (without BMI) [please submit as soon as the analysis is complete] ===
   −
There are '''4''' separate association analyses to be completed.  
+
There are '''2''' separate association analyses to be completed '''without adjusting for BMI'''.  
    
{| width="1650" border="1" align="left" cellpadding="1" cellspacing="1"
 
{| width="1650" border="1" align="left" cellpadding="1" cellspacing="1"
Line 164: Line 164:  
|-
 
|-
 
|  
 
|  
[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#A._Typical_DIAGRAM_analysis_using_existing_association_pipeline 1. &nbsp;Typical DIAGRAM analysis using existing association pipeline]  
+
[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#1._Typical_DIAGRAM_analysis_using_existing_association_pipeline A. &nbsp;Typical DIAGRAM analysis using existing association pipeline]  
   −
(with or without BMI)
+
<br>
    
|  
 
|  
Line 182: Line 182:     
|  
 
|  
A. DIAGRAMv4_iSNPs_XXX_1000G_KKK_TTT_YYY_ZZZ.txt  
+
DIAGRAMv4_iSNPs_XXX_1000G_KKK_TTT_YYY_ZZZ.txt  
   −
B. DIAGRAMv4_iSNPs_XXX_adjBMI_1000G_KKK_TTT_YYY_ZZZ.txt
+
<br>
    
|-
 
|-
 
|  
 
|  
[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#C._Analysis_of_low_frequency_variants_using_Firth_bias-corrected_logistic_regression 2. &nbsp;Analysis of low frequency variants using Firth bias-corrected logistic regression]  
+
[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#2._Analysis_of_low_frequency_variants_using_Firth_bias-corrected_logistic_regression B. &nbsp;Analysis of low frequency variants using Firth bias-corrected logistic regression]  
   −
(with or without BMI)
+
<br>
    
|  
 
|  
Line 204: Line 204:     
|  
 
|  
A. DIAGRAMv4_iSNPs_XXX_1000G_KKK_FBC_YYY_ZZZ.epacts.gz  
+
DIAGRAMv4_iSNPs_XXX_1000G_KKK_FBC_YYY_ZZZ.epacts.gz  
   −
B. DIAGRAMv4_iSNPs_XXX_adjBMI_1000G_KKK_FBC_YYY_ZZZ.epacts.gz
+
<br>
    
|}
 
|}
Line 224: Line 224:  
<br>  
 
<br>  
   −
=== Analysis for QC  ===
+
=== Analysis for QC&nbsp;[please submit as soon as the analysis is complete] ===
    
For quality control, please run an additional analysis using EPACTS on all SNPs for chromosome 20 only using the '''SCORE''' test without BMI adjustment. &nbsp;These results will be used to compare with results from the primary analyses, to ensure the new EPACTS software has been run correctly.  
 
For quality control, please run an additional analysis using EPACTS on all SNPs for chromosome 20 only using the '''SCORE''' test without BMI adjustment. &nbsp;These results will be used to compare with results from the primary analyses, to ensure the new EPACTS software has been run correctly.  
Line 238: Line 238:  
| align="center" | '''Output Filename Format'''
 
| align="center" | '''Output Filename Format'''
 
|-
 
|-
| [http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#3._Analysis_of_chromosome_20_using_logistic_regression_score_test 3. &nbsp;Analysis of chromosome 20 using logistic regression score test]&nbsp;(without BMI)  
+
| [http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#3._Analysis_of_chromosome_20_using_logistic_regression_score_test C. &nbsp;Analysis of chromosome 20 using logistic regression score test]&nbsp;(without BMI)  
 
| Score test  
 
| Score test  
 
|  
 
|  
Line 248: Line 248:  
| A. DIAGRAMv4_iSNPs_XXX_1000G_KKK_SCR_YYY_ZZZ.epacts.gz
 
| A. DIAGRAMv4_iSNPs_XXX_1000G_KKK_SCR_YYY_ZZZ.epacts.gz
 
|}
 
|}
 +
 +
<br>
 +
 +
=== Secondary analyses (with BMI)&nbsp;[please submit as soon as the analysis is complete]  ===
 +
 +
There are '''2'''&nbsp;secondary analyses'''&nbsp;adjusting for BMI'''.
 +
 +
{| width="1650" border="1" align="left" cellpadding="1" cellspacing="1"
 +
|-
 +
! scope="col" |
 +
Association Analysis
 +
 +
! scope="col" |
 +
Statistical Test
 +
 +
! scope="col" |
 +
Subset of SNPs
 +
 +
! scope="col" |
 +
Output File Type
 +
 +
! scope="col" |
 +
Output Filename Format
 +
 +
|-
 +
|
 +
[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#4._Typical_DIAGRAM_analysis_using_existing_association_pipeline_.28with_BMI.29 D. &nbsp;Typical DIAGRAM analysis using existing association pipeline (with BMI)]
 +
 +
<br>
 +
 +
|
 +
Wald or likelihood ratio
 +
 +
|
 +
All SNPs with
 +
 +
MAC &gt;= 1
 +
 +
|
 +
Custom file
 +
 +
based on DIAGRAM format
 +
 +
|
 +
DIAGRAMv4_iSNPs_XXX_adjBMI_1000G_KKK_TTT_YYY_ZZZ.txt
 +
 +
<br>
 +
 +
|-
 +
|
 +
[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#5._Analysis_of_low_frequency_variants_using_Firth_bias-corrected_logistic_regression_.28with_BMI.29 E. &nbsp;Analysis of low frequency variants using Firth bias-corrected logistic regression (with BMI)]
 +
 +
<br>
 +
 +
|
 +
Firth bias-corrected
 +
 +
|
 +
SNPs with
 +
 +
200 &gt;= MAC &gt;= 1
 +
 +
|
 +
EPACTS output file
 +
 +
|
 +
DIAGRAMv4_iSNPs_XXX_adjBMI_1000G_KKK_FBC_YYY_ZZZ.epacts.gz
 +
 +
<br>
 +
 +
|}
 +
 +
<br>
 +
 +
<br>
 +
 +
<br>
 +
 +
<br>
 +
 +
<br>
 +
 +
<br>
 +
 +
<br>
 +
 +
'''Please send the 2 Primary analyses and the QC analysis when complete.'''
    
<br>  
 
<br>  
Line 273: Line 360:  
<br> Hence, we only ask for Firth test results for SNPs with MAC &lt;= 200.  
 
<br> Hence, we only ask for Firth test results for SNPs with MAC &lt;= 200.  
   −
=== 1. Typical DIAGRAM analysis using existing association pipeline<br> ===
+
<br>  
 +
 
 +
----
   −
This is the typical DIAGRAM analysis using your current association pipeline and software. &nbsp; [[Image:1000Genomes march2012 imputation analysis plan 08312012.pdf]]
+
=== A. Typical DIAGRAM analysis using existing association pipeline<br>  ===
   −
=== 2. Analysis of low frequency variants using Firth bias-corrected logistic regression  ===
+
This is the typical DIAGRAM analysis using your current association pipeline and software. &nbsp; [[Image:1000Genomes_march2012_imputation_analysis_plan_08312012_v2.pdf]] (Updated Dec 14, 2012)
 +
 
 +
For frequently asked questions regarding the file format, please see: &nbsp;[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#Results_FIle_Clarifications genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#Results_FIle_Clarifications]
 +
 
 +
==== Alternative: &nbsp;Analyze VCF and PED files using the Wald test with the EPACTS software:  ====
 +
 
 +
As preparation for the Firth test analysis, we encourage you to analyze the data using the Wald test first, since it is computationally much faster. &nbsp;This will be a good way to check if your VCF and PED files for every chromosome are correctly formatted for EPACTS and resolve any problems you may have with your imputation or input files.
 +
<pre>EPACTS-3.0.0/epacts single -vcf [INPUT VCF FILENAME] -ped [INPUT PED FILENAME] -out [OUTPUT FILENAME PREFIX] \
 +
-test b.wald -pheno DISEASE -cov AGE -sepchr -anno -min-mac 1 -field EC -run 10
 +
</pre>
 +
'''Important:''' To analyze dosages (not genotypes), you must specify the dosage field with the "--field EC" option. Without this option, you will be analyzing the hard genotypes (i.e. --field option defaults to "GT" or "genotypes")!
 +
 
 +
=== B. Analysis of low frequency variants using Firth bias-corrected logistic regression  ===
    
The Firth bias-corrected test has well-controlled type I error rate and good power for analysis of balanced and unbalanced studies. &nbsp;However, it is more computationally intensive. &nbsp;We only run Firth on&nbsp;the subset of variants with 1&lt;= MAC &lt;= 200.  
 
The Firth bias-corrected test has well-controlled type I error rate and good power for analysis of balanced and unbalanced studies. &nbsp;However, it is more computationally intensive. &nbsp;We only run Firth on&nbsp;the subset of variants with 1&lt;= MAC &lt;= 200.  
    
To run the Firth test using the EPACTS software:  
 
To run the Firth test using the EPACTS software:  
<pre>epacts2.1/epacts single -vcf [INPUT VCF FILENAME] -ped [INPUT PED FILENAME] -out [OUTPUT FILENAME PREFIX] \
+
<pre>EPACTS-3.0.0/epacts single -vcf [INPUT VCF FILENAME] -ped [INPUT PED FILENAME] -out [OUTPUT FILENAME PREFIX] \
 
-test b.firth -pheno DISEASE -cov AGE -sepchr -anno -min-mac 1 -max-mac 200  -field EC -run 10
 
-test b.firth -pheno DISEASE -cov AGE -sepchr -anno -min-mac 1 -max-mac 200  -field EC -run 10
 
</pre>  
 
</pre>  
<br>'''Important:''' &nbsp;To analyze dosages (not genotypes), you must specify the dosage field with the "--field EC" option. &nbsp;Without this option, you will be analyzing the hard genotypes (i.e. --field option defaults to "GT" or "genotypes")!<br>
+
'''Important:''' &nbsp;To analyze dosages (not genotypes), you must specify the dosage field with the "--field EC" option. &nbsp;Without this option, you will be analyzing the hard genotypes (i.e. --field option defaults to "GT" or "genotypes")!  
   −
=== 3. Analysis of chromosome 20 using logistic regression score test  ===
+
=== C. Analysis of chromosome 20 using logistic regression score test  ===
    
The score test has well-controlled type I error rate and good power for meta-analysis of balanced (equal numbers of cases and controls) studies.&nbsp; It is also very computationally efficient.&nbsp; Please run the score test using the EPACTS software.  
 
The score test has well-controlled type I error rate and good power for meta-analysis of balanced (equal numbers of cases and controls) studies.&nbsp; It is also very computationally efficient.&nbsp; Please run the score test using the EPACTS software.  
    
The EPACTS command for the score test analysis of chromosome 20 is:  
 
The EPACTS command for the score test analysis of chromosome 20 is:  
<pre>epacts2.1/epacts single -vcf [INPUT VCF FILENAME] -ped [INPUT PED FILENAME] -out [OUTPUT FILENAME PREFIX] \
+
<pre>EPACTS-3.0.0/epacts single -vcf [INPUT VCF FILENAME] -ped [INPUT PED FILENAME] -out [OUTPUT FILENAME PREFIX] \
 
-test b.score -pheno DISEASE -cov AGE -chr 20 -anno -min-mac 1 -field EC -run 10
 
-test b.score -pheno DISEASE -cov AGE -chr 20 -anno -min-mac 1 -field EC -run 10
 
</pre>  
 
</pre>  
This command will run single variant analysis using the score test logistic regression on the DISEASE phenotype adjusting for AGE. Add the relevant additional covariates with additional "-cov" options. This assumes that the VCF files are separated by chromosomes (option -sepchr). All variants with at least one minor allele count will be analyzed (option -min-mac 1). It will annotate results by functional category (option -anno) and run the analysis on 10 parallel CPUs (option -run 10).
+
This command will run single variant analysis using the score test logistic regression on the DISEASE phenotype adjusting for AGE. Add the relevant additional covariates with additional "-cov" options. This assumes that the VCF files are separated by chromosomes (option -sepchr). All variants with at least one minor allele count will be analyzed (option -min-mac 1). It will annotate results by functional category (option -anno) and run the analysis on 10 parallel CPUs (option -run 10).  
 +
 
 +
=== D. Typical DIAGRAM analysis using existing association pipeline (with BMI)<br>  ===
 +
 
 +
This is the typical DIAGRAM analysis using your current association pipeline and software including BMI adjustment.
 +
 
 +
'''Alternative: &nbsp;Analyze VCF and PED files using the Wald test with the EPACTS software:'''
 +
 
 +
<br>
   −
== 5. &nbsp;Report EPACTS results<br> ==
+
=== E. Analysis of low frequency variants using Firth bias-corrected logistic regression (with BMI) ===
   −
For analyses 2 and 3, please upload the three .epacts.gz files to the FTP server:  
+
Again use the Firth test on EPACTS for your analysis with BMI
 +
 
 +
== 5. &nbsp;Report results<br>  ==
 +
For '''analysis 1''', please follow the following results file guidelines: &nbsp; [[Image:1000Genomes_march2012_imputation_analysis_plan_08312012_v2.pdf]] (Updated Dec 14, 2012)
 +
 
 +
For frequently asked questions regarding the file format, please see: &nbsp;[http://genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#Results_FIle_Clarifications genome.sph.umich.edu/wiki/EPACTS_for_DIAGRAM#Results_FIle_Clarifications]
 +
 
 +
 
 +
For '''analyses 2 and 3''', please upload the two epacts.gz files to the FTP server:  
    
#'''Firth test (no BMI): '''&nbsp;DIAGRAMv4_iSNPs_XXX_1000G_KKK_FBC_YYY_ZZZ.epacts.gz  
 
#'''Firth test (no BMI): '''&nbsp;DIAGRAMv4_iSNPs_XXX_1000G_KKK_FBC_YYY_ZZZ.epacts.gz  
#'''Firth test (with BMI):''' &nbsp;DIAGRAMv4_iSNPs_XXX_adjBMI_1000G_KKK_FBC_YYY_ZZZ.epacts.gz
   
#'''Score test (chr 20, no BMI): &nbsp;'''DIAGRAMv4_iSNPs_XXX_1000G_KKK_SCR_YYY_ZZZ.epacts.gz
 
#'''Score test (chr 20, no BMI): &nbsp;'''DIAGRAMv4_iSNPs_XXX_1000G_KKK_SCR_YYY_ZZZ.epacts.gz
    
<br>  
 
<br>  
 +
 +
The FTP hostname is: &nbsp;'''ftp.broadinstitute.org'''. &nbsp;Please place your files into to the /incoming/ directory.
 +
 +
    
Here's an example score test .epacts file  
 
Here's an example score test .epacts file  
Line 332: Line 452:  
*PVALUE&nbsp;: P-value
 
*PVALUE&nbsp;: P-value
   −
The rest of columns varies by statistical tests. For example, in b.score test, SCORE represents score test statistics, N.CASE and N.CTRL represents the case/control counts, and AF.CASE and AF.CTRL represents the case/control allele frequencies.  
+
The rest of columns varies by statistical tests. For example, in b.score test, SCORE represents score test statistics, N.CASE and N.CTRL represents the case/control counts, and AF.CASE and AF.CTRL represents the case/control allele frequencies.
 
  −
 
      
= Troubleshooting Common Issues  =
 
= Troubleshooting Common Issues  =
   −
== EPACTS installation errors ==
+
== EPACTS installation errors ==
 
  −
 
     −
== Errors when running EPACTS ==
+
== Errors when running EPACTS ==
    
=== Rscript execution error: No such file or directory  ===
 
=== Rscript execution error: No such file or directory  ===
Line 368: Line 484:  
If you can find Rscript (e.g. /usr/bin/Rscript, /usr/local/bin/Rscript), or if you can re-install the full Rscript, you can simply avoid the problem by setting your environment variable.  
 
If you can find Rscript (e.g. /usr/bin/Rscript, /usr/local/bin/Rscript), or if you can re-install the full Rscript, you can simply avoid the problem by setting your environment variable.  
   −
Otherwise, Hyun will modify EPACTS to not requiring this (so you can run R CMD BATCH instead of Rscript).
+
Otherwise, Hyun will modify EPACTS to not requiring this (so you can run R CMD BATCH instead of Rscript).  
    
=== ERROR: No overlapping IDs between VCF and PED file. Cannot proceed.  ===
 
=== ERROR: No overlapping IDs between VCF and PED file. Cannot proceed.  ===
Line 398: Line 514:     
</pre>  
 
</pre>  
<br> The genotype information has FORMAT "GT:EC". &nbsp;For the first SNP (chr11:180567) and individual A001, the genotype is 1/1 and dosage is 2.0000. &nbsp;To access the dosages, you must specify the option "-field EC"
+
<br> The genotype information has FORMAT "GT:EC". &nbsp;For the first SNP (chr11:180567) and individual A001, the genotype is 1/1 and dosage is 2.0000. &nbsp;To access the dosages, you must specify the option "-field EC".
 +
 
 +
 
 +
 
 +
== Results FIle Clarifications ==
 +
 
 +
=== 1. How do I code the INDEL variant names and alleles?  ===
 +
 
 +
Please use the variant name and the allele name directly from IMPUTE or minimac. Please do NOT recode variant names or alleles. We will do this step in the analysis for consistency.
 +
 
 +
ACTION IF YOU HAVE UPLOADED YOUR FILE: If you have recoded your INDEL alleles, please tell us so we can remove your file and let us know when you can reupload with the original variable and allele names.
 +
 
 +
=== <br>2. The document asks for the number of homozygotes and heterozygotes in case and control. How do I get this from my data? Is this relevant for imputed data?  ===
 +
 
 +
These numbers were relevant to genotyped data but not for imputed data. We didn't intend to ask for this. To retain the same file format between results already submitted and those to be submitted please retain the columns with a "." for the value.
 +
 
 +
ACTION IF YOU HAVE UPLOADED YOUR FILE: No action. You do not need to redo the file. We will skip these columns.
 +
 
 +
=== 3. For the "Imputed" variable, what does imputed mean in the context of the data output from MACH and IMPUTE?  ===
 +
 
 +
This is a hold over from the last round of analysis where we asked for results separately from genotyped SNPs and imputed SNPs and wanted to distinguish between the two. We will use r2_hat or info measures to estimate the accuracy of the genotypes. This column will be retained for consistency with files already submitted but should be filled in with "." or "1". It will not be used in the analysis.
 +
 
 +
ACTION IF YOU HAVE UPLOADED YOUR FILE: No action. You do not need to redo the file. We will skip this column.
96

edits

Navigation menu