This PR handles spec compliant BED12 files, so it won't work as is with BED3-9 and optional fields. Handling the other types of bed files could require creating separate reader structs for each one that build off the previous and impl different record column sizes as noodles does with BedN and Record. There may be a simpler solution. In the interim, it is still easier to read bed files with a csv reader (delimited by \t), especially given the variety of column arrangements.
Of note are 2 types of arrow builders used in the BedBatchBuilder that have not been used elsewhere in oxbow:
StructBuilder for Struct Arrays
used for the color field
ListBuilder for lists
used for the block_sizes and block_starts fields
These builders could potentially be used for the nested fields of other readers in oxbow.
This PR handles spec compliant BED12 files, so it won't work as is with BED3-9 and optional fields. Handling the other types of bed files could require creating separate reader structs for each one that build off the previous and
impl
different record column sizes as noodles does withBedN
andRecord
. There may be a simpler solution. In the interim, it is still easier to read bed files with a csv reader (delimited by\t
), especially given the variety of column arrangements.Of note are 2 types of arrow builders used in the
BedBatchBuilder
that have not been used elsewhere in oxbow:StructBuilder
for Struct Arrayscolor
fieldListBuilder
for listsblock_sizes
andblock_starts
fieldsThese builders could potentially be used for the nested fields of other readers in oxbow.