guoweilong / cgmaptools

toolbox for analysing BS-seq data, advance features in SNV, ASM and DMR
https://cgmaptools.github.io
61 stars 26 forks source link

cgmaptools mbin #46

Open zhangaicen opened 3 years ago

zhangaicen commented 3 years ago

Dear Guo, recently I tried cgmaptools for methylation analysis, I used bismark for rice methylation extractor (pair-end), and then used cgmaptools convert bismark2cgmap to generate a CGmap file, then I want to generate a genomewide methylation level by cgmaptools mbin with the command: zcat 2n-1M.CGmap.gz | cgmaptools mbin -B 10000 -c 5 -f pdf -p 2n-1M.mbin -t 2n-1M > 2n-1M.mbin.log, finally get the pdf as below: image but my pdf doesn't seem to be a right profile as I saw in a user guide, is there something wrong with my process? And I see the order of the chromosome is not like "Chr1, Chr2, Chr3...", how can I adjust the order ?I want to use cgmaptools mbin to divide the genome to some bins then used the mean methylation level of each bin to caculate the correction between replicates, is it feasible? and what is the appropriate length of the bins?

Waiting for your reply, and thanks a lot.

guoweilong commented 3 years ago

Sorry I could not access your figure. But I suggest you use *mbin.log file to re-drawing the figure through coding with R by yourself. The provided script for drawing may not make all the figures look good under different system.

Best, Weilong

At 2021-02-07 21:34:09, "zhangaicen" notifications@github.com wrote:

Dear Guo, recently I tried cgmaptools for methylation analysis, I used bismark for rice methylation extractor (pair-end), and then used cgmaptools convert bismark2cgmap to generate a CGmap file, then I want to generate a genomewide methylation level by cgmaptools mbin with the command: zcat 2n-1M.CGmap.gz | cgmaptools mbin -B 10000 -c 5 -f pdf -p 2n-1M.mbin -t 2n-1M > 2n-1M.mbin.log, finally get the pdf as below:

but my pdf doesn't seem to be a right profile as I saw in a user guide, is there something wrong with my process? And I see the order of the chromosome is not like "Chr1, Chr2, Chr3...", how can I adjust the order ?I want to use cgmaptools mbin to divide the genome to some bins then used the mean methylation level of each bin to caculate the correction between replicates, is it feasible? and what is the appropriate length of the bins?

Waiting for your reply, and thanks a lot.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

zhangaicen commented 3 years ago

Hi Guo, I have 8 samples but when checked the *mbin.log , I found that they were divided into different numbers of bins, wc after carefully checking the file, I found there were some differences in Chr9, for example, the last interval in sample1 is Chr9:22960001 -22970000, while it is Chr9:22990001-23000000 in sample2,Chr9: 22990001-23000000 in sample3... So how should I deal with this issue?

Thank a lot. Zhang

guoweilong commented 3 years ago

It seems some samples might have low coverage at the ends of chromosomes. You can add 0 to fill corresponding regions manually.

Best, Weilong

At 2021-02-08 11:25:02, "zhangaicen" notifications@github.com wrote:

Hi Guo, I have 8 samples but when checked the *mbin.log , I found that they were divided into different numbers of bins,

after carefully checking the file, I found there were some differences in Chr9, for example, the last interval in sample1 is Chr9:22960001 -22970000, while it is Chr9:22990001-23000000 in sample2,Chr9: 22990001-23000000 in sample3... So how should I deal with this issue?

Thank a lot. Zhang

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

zhangaicen commented 3 years ago

Fine, I've got it, thanks.