Writing to 2Bit files

To write a 2Bit file, you have to use a TwoBit.Writer.

TwoBit.WriterType
TwoBitWriter(output::IO, names::AbstractVector)

Create a data writer of the 2bit file format.

Arguments

  • output: data sink
  • names: a vector of sequence names written to output
source

TwoBit.Writer wraps an IO type, and must be provided a set of names of the sequences that shall be written on construction.

To write a sequence to 2Bit file, create a TwoBit.Record using the sequence and then use the Base.write method.