Last active
April 23, 2016 03:54
-
-
Save dnbaker/0886c010ad21be2189a6 to your computer and use it in GitHub Desktop.
Get list of all quality scores found in quality strings in a bam
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pysam | |
from itertools import chain | |
def get_qchars(bampath): | |
return set(chain.from_iterable(set(c.qual) for | |
c in pysam.AlignmentFile(bampath))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment