GaetanBenoitDev / metaMDBG

MetaMDBG: a lightweight assembler for long and accurate metagenomics reads.
MIT License
105 stars 4 forks source link

Calculating coverage of an assembly #21

Open Sung-hub opened 1 month ago

Sung-hub commented 1 month ago

Is there a way to calculate coverage of an metaMDBG assembly? I can see each contigs has its own coverage, but I would like to see average/median depth of an assembly to compare different assemblies I create.

GaetanBenoitDev commented 1 month ago

Coverage information provided by tools is often the average. If you want the median I think you have to script it. What I would is to map the reads to the contigs with minimap2, provide the bam to bedtools which provide the per base coverage, then you can compute the metrics you need from that.