Adding depth data to a graph
Thanks for all your great work advancing this fork of Bandage.
I'm working with a Miniasm graph that does not have contig depth data stored in the gfa file and I'd like to add depth information calculated with another tool (i.e. Mosdepth).
-
If I manually add this information into the gfa, what is the format of the tag where Bandage will look for depth data? I'm guessing this will be a tag on the Segment lines?
-
As an alternative, it would be great to have an option to bulk import depth data from csv rather than having to use the "Change node depth" option on each individual contig. I see that I can make a custom field under "CSV data" but I'd prefer to explicitly add this info to the Depth field.
I found the GFA tag name info on your wiki.
I'll add a slightly different question: If I have a BED file with coverage information for windows across a contig, is it possible to colour the intervals by their values?
It would be useful to have a kind of heatmap of read depth across a contig.
Re depth tags: Unicycler seems to use dp as a depth tag instead of DP so is not picked up by BandageNG.
This can be fixed with:
sed -i 's/dp:f/DP:f/g' Unicycler_asm.gfa
Can dp be added as a tag that Bandage looks for?
Bandage-NG supports various options for specifying depths from GFA: https://github.com/asl/BandageNG/wiki/Custom-GFA-tags#node-depths
As GFA tags are case sensitive, dp and DP technically are different tags.
Seeing as unicycler produced assemblies with dp, could you add that as a depth option?
Apparently, lowercase dp is used as it is not standardized in the GFA spec: see this thread.
Seeing as unicycler produced assemblies with
dp, could you add that as a depth option?
Yes, sure.
Fixed in https://github.com/asl/BandageNG/commit/a57ef610054560c49b1036c1f81c0bdf70af0df2