skbio.sequence.DNA.to_definites#
- DNA.to_definites(degenerate='wild', noncanonical=True)[source]#
Convert degenerate and noncanonical characters to alternative characters.
- Parameters:
- degenerate{“wild”, “gap”, “del”, str of length 1}, optional
How degenerate/non-canonical characters should be treated: Replace them with the wildcard character (“wild”, default), or the default gap character (“gap”), or a user-defined character (str of length 1), or remove them (“del”).
- noncanonicalbool, optional
Treat non-canonical characters in the same way as degenerate characters (
True
, default), or leave them as-is (False
).
- Returns:
- GrammaredSequence
Converted version of the sequence.