Question: Aligning Reads To Specific Chromosome Using Bwa
2
gravatar for KS
4.2 years ago by
KS310
KS310 wrote:

Hello Everyone,

I have whole genome illumina paired end reads and I want to align my reads to specific chromosome (chr 21) using BWA.

I was thinking of aligning the entire reads to fasta file of the human chromosome 21. Is this the appropriate way to solve my problem or is there any specific command for BWA to solve this.

Any kind of help is appreciated

Thanks Suz

paired-end bwa • 3.5k views
ADD COMMENTlink modified 4.2 years ago by Chris Miller18k • written 4.2 years ago by KS310
6
gravatar for Chris Miller
4.2 years ago by
Chris Miller18k
Washington University in St. Louis, MO
Chris Miller18k wrote:

Are you sure this is actually what you want to do? If you align reads from the whole genome to only chromosome 21, you will get false alignments.

There are many regions with high similarity in the genome. For the purposes of illustration, let's imagine small regions on chromosome 1 and chromosome 21 that differ only by two base pairs. If you align only to chromosome 21, reads drawn from chromosome 1 will get matched up with their best alignment, which will be the highly similar region on chromosome 21. If you aligned against the whole genome, though, they would find a better (and correct) match on chr1. Thus, in many cases, it makes sense to align to the whole genome first, then subset out your chromosome 21 reads from the alignment file.

If aligning to chr21 is really what you want to do, you should follow the instructions given by Sangwoo Kim - just create a new BWA index using only the chromosome 21 fasta.

ADD COMMENTlink written 4.2 years ago by Chris Miller18k
3
gravatar for Sangwoo Kim
4.2 years ago by
Sangwoo Kim340
UC San Diego
Sangwoo Kim340 wrote:

You can do this simply by giving a specific chromosome instead the whole genome assembly as a reference fasta. For example, you can download an individual human reference at http://hgdownload.soe.ucsc.edu/goldenPath/hg19/chromosomes/ Please check the reference version is right.

And you can proceed like this.

bwa aln chr21.fa your_read.fastq > your_read.sai
bwa samse chr21.fa your_read.sai your_read.fastq > yours.sam

As the above answer commented, you might need to index it differently if the chromosome is very short. But even the shortest human chromosome is still larger than 10MB, I think the bwtsw algorithm should work. (except the mitochondrial chromosome or other short unassembled contigs)

bwa index -a bwtsw chr21.fa
ADD COMMENTlink written 4.2 years ago by Sangwoo Kim340
1
gravatar for fo3c
4.2 years ago by
fo3c420
.eu
fo3c420 wrote:

As far as I know there is no way to tell bwa to use a specific chromosome as reference. I would thus bwa index chromosome 21 with an appropriate algorithm (very small "genome") and align against it.

ADD COMMENTlink written 4.2 years ago by fo3c420
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 404 users visited in the last hour