genome / bam-readcount

Count bases in BAM/CRAM files
MIT License
298 stars 95 forks source link

Getting the read names/ IDs? #68

Open ghost opened 4 years ago

ghost commented 4 years ago

Hello,

I was wondering if there was a way to get the read names for each base. For example, let's say at the position 237 there are 20 reads supporting A and 10 supporting C, is it possible to have the names of the reads supporting the A and the names of the reads supporting the C?

dridk commented 4 years ago

I would like this feature too... @aderzelle Did you find another way to do this ?

ghost commented 4 years ago

@dridk I found bamql https://github.com/BoutrosLaboratory/bamql it does have an option, nt_exact, to specify what nucleotide value you want at position x, relative to the chromosome coordinates. It is slow, though

It could be that https://github.com/vibansal/HapCUT2 also gives that, one would need to parse the compact frag file I guess (I haven't looked into it yet).

dridk commented 4 years ago

Whaoo ! Bamql is awesome ! I added your suggestion on biostar ! https://www.biostars.org/p/322664/#450406

ghost commented 4 years ago

yes, I don't really understand why it does not have more use ^^'

could be very few people need to make such specific queries, I guess.