Editing a Plasmid Without Breaking Its Features
6 min read · Updated October 30, 2026
Most sequence viewers show you a map. Editing the sequence under that map is a different problem, because every annotation is a pair of coordinates and an edit moves the sequence those coordinates point at.
Here is exactly what happens to three features through four kinds of edit, including the two cases that have no automatic answer.
The starting point
A 90 bp construct with three features: a promoter at 1–20, a CDS at 25–75, and a terminator at 80–90 on the reverse strand. Every example below is the same construct with one edit applied.
An insertion moves everything after it
Insert 10 bases immediately after base 20 and the promoter stays at 1–20, the CDS moves from 25–75 to 35–85, and the terminator from 80–90 to 90–100. Each coordinate after the insertion point gains exactly the length of the insert.
That is the behaviour that makes editing usable: paste a tag in front of a gene and the gene is still annotated, rather than the annotation now naming ten bases of tag and ending ten bases short.
A deletion is the mirror. Delete bases 41–46, six bases inside the CDS, and the CDS runs 25–69 — its start is before the cut and does not move, its end comes back by six — while the terminator moves from 80–90 to 74–84.
An edit that cuts a feature in half has no automatic answer
Delete bases 71–85 and the deletion takes the last five bases of the CDS and the first six of the terminator. Neither feature can be moved, because neither is intact afterwards.
The right behaviour is to apply nothing and ask. Both conflicts are named — the edit would delete part of this feature's end, for the CDS, and part of this feature's start, for the terminator — and the choice per feature is to trim it to what survives or to delete it outright.
Choose trim and the CDS becomes 25–70 and the terminator 71–75, both relabelled as trimmed, so the map does not silently claim a feature is intact. Choose delete and both disappear from the map, and the edit proceeds with the promoter alone.
Applying the edit and shrinking the features silently is the behaviour to avoid: a CDS whose annotation was quietly trimmed is a CDS that no longer starts where it says it does.
A feature that spans the origin is the case that breaks naive code
A circular plasmid's numbering starts at an arbitrary base, so a feature can begin near the end and finish near the beginning — 85 to 5 on a 90 bp circle, with a start greater than its end.
Insert those same 10 bases after base 20 and the feature becomes 95 to 5. Its first half moved, because it lies after the insertion point; its second half did not, because it lies before. Any code that assumes start is less than end gets this wrong, usually by producing a feature of negative length or by silently dropping it.
This is worth testing on your own tools before trusting a map through an edit, because the failure is visible only to someone who knows what the feature was.
What else has to survive an edit
- The strand. A feature on the reverse strand is still on the reverse strand after an insertion somewhere else.
- Undo, and at a sensible granularity: a bounded history that coalesces rapid typing into single steps, so one undo removes a word rather than a character.
- The file. An edited map is worth nothing if it cannot be written back out as GenBank, with the features where the editing put them.
- Re-annotation as a separate action. Features you added by hand should not be replaced by a signature scan without being asked.
Frequently asked questions
What happens to annotations when I insert bases into a plasmid?
Everything after the insertion point moves by the length of the insert, and everything before it stays. A feature containing the insertion point grows by the same amount. Inserting 10 bases after base 20 of a worked construct leaves a 1–20 promoter untouched and moves a 25–75 CDS to 35–85.
What happens if my edit deletes part of a feature?
There is no correct automatic answer, so the edit should stop and ask. The two defensible outcomes are to trim the feature to the part that survives — labelled as trimmed, so the map does not claim it is intact — or to delete it. Shrinking it silently produces a CDS that no longer starts where its annotation says.
How are features that span a circular plasmid's origin handled?
By treating start greater than end as a real, wrapping feature rather than as an error. An insertion before the origin moves the feature's first half and leaves its second half alone: a feature at 85–5 becomes 95–5 after ten bases are inserted at position 20. Code that assumes start is less than end gets this wrong silently.
Can I edit a sequence and keep the SnapGene file?
You can read one, edit it and write GenBank or .dna back out. What travels is the sequence and the feature table; what a round trip does not promise is byte-identity with the original file, since vendor formats carry blocks that are not part of the map.
Related references
Related tools
Type or paste a sequence and edit it directly — every feature remaps live as you insert, delete, or replace bases, with undo/redo and GenBank import/export.
Auto-detect promoters, tags, origins and resistance markers in a plasmid, then run a deep scan against pLannotate's full feature databases.
Paste a GenBank record and see an annotated circular or linear map with a feature table.
Open a SnapGene .dna file and read its sequence, features, colors and primers — no SnapGene, no account.
Render a circular or linear map with restriction sites.