nanoporetech / modkit

A bioinformatics tool for working with modified bases
https://nanoporetech.com/
Other
128 stars 7 forks source link

Feature request: Auto bgzip/tabix a pileup #144

Open billytcl opened 6 months ago

billytcl commented 6 months ago

For the dmr pipeline, it requires having to bgzip/tabix a pileup bed file. Is there a way to have modkit to automatically generate this as an option in the "pileup" command? Eg. --bgzip as an option in the pileup command?

ArtRand commented 6 months ago

Hello @billytcl,

Making the output of pileup directly consumable by dmr is already on the roadmap actually.

You can compress the bedMethyl output on the fly:

# passing `-` as the output string will make the output go to stdout
$ modkit pileup $in_bam - | bgzip -c > $out_bedmethyl_gz

I appreciate that keeping all these programs around in all your environments might get annoying (and you still have to run tabix).

The main reason for dragging on and not having a 1-2 step solution is that I'm not sure if I'll stick with bgzip/tabix or go to some other format like bigBed.