Open main menu

Genome Analysis Wiki β

1000 Genomes Project Pilot 1 SNP Calling

Revision as of 13:23, 10 March 2010 by Ylwtx (talk | contribs) (=)

Michigan Pilot One SNP calling work flow:


(1) Create GLF files from BAM files


key command: samtools pileup
Source codes: Check with Paul for the latest version

output GLF format: bgzf

(file size) BAM (binary SAM) file: up to 43Gb (average 10s Gb) for each individual
(file size) GLF (binary) file: up to 19Gb (average 10s Gb) for each individual

(2) Split GLF files by chromosome



key command: glfSplit
Source codes: ~goncalo/code/glfSplit/

Input GLF format: gz or bgzf
Output GLF format: gz

Tom suggested combing the first two steps using the following samtools command:
samtools -view -u *.bam 22 | samtools pileup –g - > *.glf

(3) Build a list of individuals within each population


STEP 0 in s1-5.csh

Note: Check to make sure that all the individuals with GLF are included in the list “”

(4) Link files and tabulate # of files per population, per platform


STEP 1 in s1-5.csh

key command: ln -s

(5) Check total (aggregated over all individual samples) depth for each population, each platform


STEP 2 in s1-5.csh

key command : DepthDistr
Source codes : /home/ylwtx/codes/cpp/DepthDistr/
Input : GLF files
Output : PMF and CDF of total depth distribution

Other: total depth for each site (for vcf) (run after filter)
key command : DepthPerSite
Source codes : /home/ylwtx/codes/cpp/ DepthPerSite/
Input : GLF files
Output : total depth for each site

(6) Filter sites with total depth at the extremes, within each population, each platform


STEP 3 in s1-5.csh

key command : filterGLF or filterGLF_notBGZF
Source codes : /home/ylwtx/codes/cpp/filterGLF
Input : GLF files
Output : GLF files

minMapQ = 30

(7) Obtain one merged GLF for each individual by merging GLFs across platforms for the same individual


STEP 4 in s1-5.csh

key command : glfMerge or glfMerge_noBGZF
Source codes : /home/ylwtx/codes/cpp/glfMerge
Originally ~goncalo/code/glfMerge
Input : GLF files for one individual
Output : GLF file

(8) Promote a set of sites for each population


STEP 5 in s1-5.csh

key command : GPT_Freq
Source codes : /home/ylwtx/codes/cpp/glfmultipes_prethunder/GPT_Freq_old
Originally ~goncalo/code/glfMultiples

Parameters set:
(1) Posterior probability (for being a polymorphism) threshold: 0.999 (0.9 for genomewide but need test)
(2) minMapQ = 30
(3) –allhet default is ON
Input: GLF
Output: simplified GLF with three likelihoods

(9) Merge with genotype data

(9.1) prepare genotype data in a unified format


See: readme.procedure.txt*

key command : ped_prethunder_freq
Source codes : /home/ylwtx/codes/cpp/ped_prethunder

  • special thanks to Wei Chen for preparing the genotype files

(9.2) merge genotype data with sequence data at promoted sites


STEP 6 in s1-5.csh

key command : merge_prethunder_freq
Source codes : /home/ylwtx/codes/cpp/merge_prethunder

Sites with more than two alleles (not including REF_ALLELE) will be discarded

** Include genotypes only for individuals that have sequence data

(10) Run thunder (hidden Markov model)


STEP 7 in s1-5.csh
Or prep_and_get_thunder_jobs.chr.*csh

key command : thunder_glf_freq
Source codes : /home/ylwtx/codes/cpp/mach-1.0.16

(1) Cleaned monomorphic sites before feeding to thunder (no need, b/c thunder 005 handles AL1/-)
(2) All sites are bi-allelic with one of the alleles being the reference allele (sites with more than 2 alleles including the reference allele are discarded at the beginning of thunder run: initially because of a prior dependent on the reference allele. In the current setting, where Freq1 is used for the prior, we can choose to ignore the reference allele information.)
a. Codes changed on 2009-11-02
(3) Split:


1-2 3-4

5-6 7-8


10-12 13-15

Total 150 jobs (50 jobs for each population)

(11) Ligate thunder results for larger chromosomes


ligate.all. 2009-10-27.csh

(12) Extract QC+ sites


share.QC+hap. csh (moved to share/ but works under the parent dir, with and without QC)
share/share.csh (with and without QC)
share.QC+dose.csh (moved to share/ but works under the parent dir, with and without QC)
without QC: for VCF

(1) Check for individuals who are genotyped only:
For example, before 2009-12, in CHB+JPT, the following 2 individuals are sequenced:
(2) Check for trios whose sequencing information were not used: e.g., daughter and father of the trio

(13) Generate other information for VCF format (no longer needed, already generated)

site.depth.csh (no longer needed, generated in GLF step)

(14) Generate VCF


(15) Quality check


(A) Accuracy of genotype calls
or eval.r2_hat.csh
(B) Accuracy of haplotype calls