# Bio.SeqIO.XdnaIO module

Bio.SeqIO support for the “xdna” file format.

The Xdna binary format is generated by Christian Marck’s DNA Strider program and also used by Serial Cloner.

class Bio.SeqIO.XdnaIO.XdnaIterator(source)

  Bases: `SequenceIterator`

  Parser for Xdna files.

  modes = 'b'
  __init__(source)

    Parse a Xdna file and return a SeqRecord object.

    Argument source is a file-like object in binary mode or a path to a file.

    Note that this is an “iterator” in name only since an Xdna file always contain a single sequence.

  __next__()

    Return the next SeqRecord.

    This method must be implemented by the subclass.

  __abstractmethods__ = frozenset({})
  __annotate_func__ = None
  __annotations_cache__ = {}
  __firstlineno__ = 145
  __parameters__ = ()
  __static_attributes__ = ('_header',)

class Bio.SeqIO.XdnaIO.XdnaWriter(target: IO | PathLike | str | bytes)

  Bases: `SequenceWriter`

  Write files in the Xdna format.

  modes = 'b'
  write_records(records)

    Write the specified record to a Xdna file.

    Note that the function expects a list (or iterable) of records as per the SequenceWriter interface, but the list should contain only one record as the Xdna format is a mono-record format.

  __abstractmethods__ = frozenset({})
  __annotate_func__ = None
  __annotations_cache__ = {}
  __firstlineno__ = 224
  __parameters__ = ()
  __static_attributes__ = ('_has_truncated_strings',)

Biopython v: 1.86

Versions
  Previous
  Latest
  Develop

Biopython Project
  Homepage
  On GitHub