I have a bismark aligned bam file, and I would like to extract the number of methylated CpGs and the number of unmethylated CpGs for each read in the bam file.
I have a bismark aligned bam file, and I would like to extract the number of methylated CpGs and the number of unmethylated CpGs for each read in the bam file.
I believe I found the answer to my question here. counting number of CpGs that are methylated and unmethylated in a read of whole genome bisulfite data
Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
I know how to extract methylation calls using bismark. When you use bismark to call methylation, it will give you the number of methylated and unmethylated reads overlapping each CpG site in the genome. But that's not my question.
I want to know all the methylated and unmethylated sites on each read.
For example, the first read in the bam file might overlap 4 CpG sites. I would like to know how many of those CpG sites were methylated and how many were unmethylated.