skbio.sequence.DNA.__iter__ΒΆ

DNA.__iter__()[source]ΒΆ

Iterate over positions in this sequence.

State: Stable as of 0.4.0.

Yields:

Sequence

Single character subsequence, one for each position in the sequence.

Examples

>>> from skbio import Sequence
>>> s = Sequence('GGUC')
>>> for c in s:
...     str(c)
'G'
'G'
'U'
'C'