Skip to main content

Compute tree distance using a method by Lin et al

Project description

tree_matching_distance

An implementation of the tree distance metric suggested by Lin, Rajan, and Moret, at ISBRA 2011.

Description

This package contains a function to import and provides a command-line tool that compares two given trees and return a distance between them.

Usage

Run the program like

  tree_matching_distance t1.tree t2.tree

where the two file parameters contain trees in Newick format on the same taxa.

To use the distance method from within your own code, write

  from ete3 import Tree
  from tree_matching_distance import distance
  t1 = Tree('((a, b), (c, d));')
  t2 = Tree('((a, c), (b, d));')
  d = distance(t1, t2)
  print(d)

for a simple test. Note that this package requires ETE3 trees.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tree_matching_distance-1.0.7-py2.py3-none-any.whl (4.0 kB view details)

Uploaded Python 2Python 3

File details

Details for the file tree_matching_distance-1.0.7-py2.py3-none-any.whl.

File metadata

  • Download URL: tree_matching_distance-1.0.7-py2.py3-none-any.whl
  • Upload date:
  • Size: 4.0 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.18.4 setuptools/40.0.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.3

File hashes

Hashes for tree_matching_distance-1.0.7-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 2399e559ef8d4db1dc6e8c198d1a32b45095ca547e96a1b5773a36749d7360de
MD5 ecb340cb95fe161673ffb1772496f3c0
BLAKE2b-256 56a034e52ab18a1b36e440b4ff40678e7017c51aece10362696aee28173d271f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page