clear_annotation
Strip all XML region tags and non-molecular characters from sequences, then
uppercase the result. This produces clean, undecorated sequences suitable for
export (e.g., writing to FASTA) or for operations that do not accept tagged
input. When a region= is specified, only the content inside that tagged
segment is cleaned; the outer tags themselves are removed from the output
according to the remove_tags setting.
import poolparty as pp
pp.init()
Parameters
Parameter |
Type |
Default |
Description |
|---|---|---|---|
|
|
(required) |
Parent pool or sequence string to transform. |
|
|
|
Region to transform: marker name, |
|
|
|
If |
|
|
|
Enumeration order when combined with other pools. |
|
|
|
Prefix for sequence names in the resulting pool. |
Note
Only the most commonly used parameters are shown above. For the full
parameter list, see clear_annotation() in the
API Reference.
Examples
Clear annotation before saving to FASTA
Chain clear_annotation so downstream steps see plain uppercase
sequences with no markup characters.
wt = pp.from_seq("AAAA<cre>ATCG</cre>TTTT")
mutants = pp.mutagenize(wt, num_mutations=1, region="cre", mode="random")
clean = pp.clear_annotation(mutants)
clean.print_library()
See clear_annotation().