Python 0.3.6
Minor feature release
Notebook detailing the new features here: https://gist.github.com/benjeffery/aff619fd8da6799bccab81655c391965
Breaking changes
Mutation.positionandMutation.indexwhich were deprecated in 0.2.2 (Sep '19) have
been removed.
Features
-
Add direct, copy-free access to the arrays representing the quintuply-linked structure
ofTree(e.g.left_child_array). Allows performant algorithms over the tree
structure using, for example, numba
(@jeromekelleher, #1299, #1320). -
Add fancy indexing to tables. E.g.
table[6:86]returns a new table with the
specified rows. Supports slices, index arrays and boolean masks
(@benjeffery, #1221, #1348, #1342). -
Add
Table.appendmethod for adding rows from classes such asSiteTableRowand
Site(@benjeffery, #1111, #1254). -
SVG visualization of a tree sequence can be restricted to displaying between left
and right genomic coordinates using thex_limparameter. The default settings
now mean that if the left or right flanks of a tree sequence are entirely empty,
these regions will not be plotted in the SVG (@hyanwong, #1288). -
SVG visualization of a single tree allows all mutations on an edge to be plotted
via theall_edge_mutationsparam (@hyanwong,#1253, #1258). -
Entity classes such as
Mutation,Nodeare now python dataclasses
(@benjeffery, #1261). -
Metadata decoding for table row access is now lazy (@benjeffery, #1261).
-
Add html notebook representation for
Treeand changeTree.__str__from dict
representation to info table. (@benjeffery, #1269, #1304). -
Improve display of tables when
printed, limiting lines set via
tskit.set_print_options(@benjeffery,#1270, #1300). -
Add
Table.assert_equalsandTableCollection.assert_equalswhich give an exact
report of any differences. (@benjeffery,#1076, #1328)
Changes
- In drawing methods
max_tree_heightandtree_height_scalehave been deprecated
in favour ofmax_timeandtime_scale
(@benjeffery,#1262, #1331).
Fixes
- Tree sequences were not properly init'd after unpickling
(@benjeffery, #1297, #1298)