GfaPy: a Flexible and Extensible Software Library for Handling Sequence Graphs in Python.
SUMMARY:GFA 1 and GFA 2 are recently defined formats for representing sequence graphs, such as assembly, variation or splicing graphs. The formats are adopted by several software tools. Here, we present GfaPy, a software package for creating, parsing and editing GFA graphs using the programming language Python. GfaPy supports GFA 1 and GFA 2, using the same interface and allows for interconversion between both formats. The software package provides a simple interface for custom record types, which is an important new feature of GFA 2 (compared to GFA 1). This enables new applications of the format.AVAILABILITY AND IMPLEMENTATION:GfaPy is available open source at https://github.com/ggonnella/gfapy and installable via pip.CONTACT:gonnella@zbh.uni-hamburg.de.SUPPLEMENTARY INFORMATION:Supplementary data are available at Bioinformatics online.