Positions of variant in certain depth
1
0
Entering edit mode
5.2 years ago
avichaireich ▴ 10

Hello. I have a SAM file and a referance genome. I'm trying to get a list of all the positions that in the referance it has A and in the alternative is has C, with total depth of at least 20X.

I don't need to do variant call, only get the list of the positions.

I'm a bit lost in this, I'll be happy for help solving it.

Thank you.

sam variant • 747 views
ADD COMMENT
0
Entering edit mode

Thank you for the quick reply! How can I know what is the depth of each allele?

ADD REPLY
0
Entering edit mode
5.2 years ago
samtools mpileup --reference  ref.fa in.bam  |\
awk -F '\t' '(toupper($3)=="A" && $4>20 && index(toupper($5),"C")>0 )' | cut -f1,2
ADD COMMENT
0
Entering edit mode

Thank you for the quick reply! How can I know what is the depth of each allele?

ADD REPLY

Login before adding your answer.

Traffic: 1671 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