vgteam / vg

tools for working with genome variation graphs
https://biostars.org/tag/vg/
Other
1.1k stars 193 forks source link

edges should be included in paths #56

Open ekg opened 9 years ago

ekg commented 9 years ago

The protobuf format doesn't currently have a way to represent when edges are part of paths.

Case in point (from the test directory):

➜  test git:(master) ✗ vg construct -r tiny/tiny.fa >t.vg; vg align -s CAAATAAGGCTTGGAAATTATATTCCAACTCTCTT -Q query t.vg | vg mod -i - t.vg | vg view -
H       HVN:Z:1.0
S       2       CAAATAAGGCTTGGAAATT
P       2       x       +       19M
L       2       -       5       +       0M
L       2       -       4       +       0M
S       4       TTCTGGAGTTCTATT
P       4       x       +       15M
L       4       -       5       +       0M
S       5       ATATTCCAACTCTCTG
P       5       x       +       16M

Nothing in the GFA output (or other output) can refer to the added path query. This is a problem with the schema itself.

ekg commented 8 years ago

The other way to resolve this is to store the path as a literal list of nodes that are traversed (or mappings against nodes, in vg terminology).

adamnovak commented 7 years ago

@ekg Do we still want to do this?

jeizenga commented 7 years ago

Aren't paths already a list of nodes that are traversed?

adamnovak commented 7 years ago

Yes, they are. We have mappings, and when two adjacent mappings are on either side of an edge, the edge is traversed.

I'm not really sure what problem Erik's original example is getting at. I thought this issue was about adding support for a path to be e.g. just an edge, but now I'm not so sure.