Skip to content

Commit e8547cc

Browse files
Merge pull request #229 from hyanwong/patch-42
Add a sort so people aren't caught out.
2 parents 9caa020 + c5cea70 commit e8547cc

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tables_and_editing.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,12 +603,13 @@ edge_table.set_columns(
603603
edge_table
604604
```
605605

606-
And finally we can add a site and a mutation: here we'll use 0/1 mutations rather than
606+
Finally we can add a site and a mutation: here we'll use 0/1 mutations rather than
607607
ATGC.
608608

609609
```{code-cell} ipython3
610610
site_id = tables.sites.add_row(position=500.0, ancestral_state='0')
611611
tables.mutations.add_row(site=site_id, node=2, derived_state='1')
612+
tables.sort() # make sure the edges & sites are in the right order
612613
ts = tables.tree_sequence()
613614
print("A hand-built tree sequence!")
614615
ts.draw_svg(y_axis=True)

0 commit comments

Comments
 (0)