FreeBayes: Bayesian genetic variant detector

Haplotype-based variant detection from short-read sequencing.

Website: https://github.com/ekg/freebayes
Citation: http://arxiv.org/abs/1207.3907

Installing dependencies

sudo apt-get update
sudo apt-get install build-essential
sudo apt-get install -f
sudo apt-get install g++
sudo apt-get install zlib1g-dev
sudo apt-get install tabix

CMAKE dependence

wget http://www.cmake.org/files/v2.8/cmake-2.8.11.tar.gz
./bootstrap
make
sudo make install

Installation of FreeBayes

$sudo apt-get install git
$git clone --recursive git://github.com/ekg/freebayes.git
$make && sudo make install

Steps to SNP call

#index the reference fasta
samtools faidx ref.fasta

#convert all SAM files to BAM files by using samtools and the reference fasta indexed (*.fasta.fai)
samtools view -bt ref.fasta.fai alignment.sam > alignment.bam

#sort the BAM files
samtools sort alignment.bam $alignment.sorted

#index BAM files
samtools index $indexar

#apply BAQ
samtools calmd -Abr alignment.sorted.bam ref.fasta > alignment.baq.bam

#index the *.baq.bam files
samtools index alignment.baq.bam

#SNP call using the *.baq.bam files
freebayes --min-base-quality 20 -p 1 --fasta-reference ref.fasta alignment.baq.bam > snpcall.vcf

See more about SAMtools here.

This entry was posted in Local Tools. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s