Filter a sam file by alignment score.
0
1
Entering edit mode
8.2 years ago
hxlei613 ▴ 100

I'm processing pair-end WGBS data following this article : Single Nucleotide Analysis of Cytosine Methylation by Whole-Genome Shotgun Bisulfite Sequencing.

In brief, read 1 are C to T converted and read 2 are G to A converted.Then the reads were aligned to an in silico converted hg19 to both the top (C to T) and bottom (G to A) strands using BWA. It uses bwa aln and bwa sampe commands.

After getting mapping results, I want to do some filter, such as alignment score. However I can't find AS tags in the optional fields. Where is the alignment score ?

In this condition, can I do filter on alignment score ?

Thank you very much for any idea.

bwa alignment score • 2.7k views
ADD COMMENT
0
Entering edit mode

It seems that AS tag is reported by bwasw and is long-read specific according to Bio-bwa-help. Can I do filter on alignment score?

ADD REPLY
0
Entering edit mode

If the alignment score is not present in your data, then it's not possible to filter by that parameter. What exactly are you trying to accomplish?

ADD REPLY
0
Entering edit mode

I just want to filter reads with alignment scores less than 1 before subsequent analysis.

ADD REPLY
0
Entering edit mode

what optional fields are you talking about? which program are you using? you can load a sam file into R, create a table, then sort the columns according to you specifications, for example. (needs basic R programming skills)

ADD REPLY
0
Entering edit mode

AS tag, it means alignment score.I am using bwa( bwa aln and bwa sampe ).

ADD REPLY

Login before adding your answer.

Traffic: 2473 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6