Question: Counting methylated and unmethylated CpGs in BSseq reads from bam file
0
gravatar for johnsonn573
17 days ago by
johnsonn5730 wrote:

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.

sequencing sequence R • 140 views
ADD COMMENTlink modified 16 days ago • written 17 days ago by johnsonn5730

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.

ADD REPLYlink written 16 days ago by johnsonn5730
1
gravatar for johnsonn573
16 days ago by
johnsonn5730 wrote:

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

ADD COMMENTlink written 16 days ago by johnsonn5730
1

Bismark calls methylation values and stores the calls in the XM tag of each read in the BAM file. You can use MethylDackel do this, or you can count the number of 'z' and 'Z' characters for each read (pair) in the BAM

ADD REPLYlink written 16 days ago by james.hawley10

Thank you! This is very helpful!

ADD REPLYlink written 16 days ago by johnsonn5730
0
gravatar for ATpoint
17 days ago by
ATpoint19k
Germany
ATpoint19k wrote:

Please read the manual for extraction the methylation calls.

ADD COMMENTlink written 17 days ago by ATpoint19k

Yes, I know how to do this, but I am not trying to extract methylation calls. See my other comment.

ADD REPLYlink written 16 days ago by johnsonn5730
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 2146 users visited in the last hour