Skip to main content

A package to compute the Robinson Fould distance extended to labeled topologies.

Project description

pylabeledrf

pylabeledrf is a heuristic to compute an extension of the Robinson Foulds tree topological distance between labeled topologies, where inner nodes are labeled with speciation or duplication events.

Citation

If you use our package in your work, please consider citing:

Samuel Briand, Christophe Dessimoz, Nadia El-Mabrouk, Manuel Lafond, Gabriela Lobinska, Extending the Robinson-Foulds distance to reconciled trees, submitted

Installation

The package requires Python 3 (>=3.6). The easiest way to install is using pip, to install the package from PyPI.

pip install pylabeledrf

Documentation

Documentation is available here.

Example

from pylabeledrf.computeLRF import *
import dendropy
taxa = dendropy.TaxonNamespace()

# retrieve the test TP53 reconciled tree (from Ensembl compara 96)
p53 = dendropy.Tree.get_from_url(
    'https://raw.githubusercontent.com/DessimozLab/pylabeledrf/master/test/p53.nhx', 
    'newick', taxon_namespace=taxa)
t1 = parseEnsemblLabels(p53)

# introduce 5 random edits and compute the distance
t2 = mutateLabeledTree(t1, 5)
computeLRF(t1,t2)

# randomise the labels and compute the distance
t3 = randomLabels(t1)
computeLRF(t1,t3)

License

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Project details


Download files

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

Source Distribution

pylabeledrf-0.1.1.tar.gz (6.8 kB view details)

Uploaded Source

Built Distribution

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

pylabeledrf-0.1.1-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file pylabeledrf-0.1.1.tar.gz.

File metadata

  • Download URL: pylabeledrf-0.1.1.tar.gz
  • Upload date:
  • Size: 6.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.11.1 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.23.4 CPython/3.5.2

File hashes

Hashes for pylabeledrf-0.1.1.tar.gz
Algorithm Hash digest
SHA256 a0b968079b0058bf1aefcf75a629e890fedca9c1e0b877b566f7bbec51c64f3f
MD5 d6c8b4cade03a76e6280fd430d75331f
BLAKE2b-256 b7ccf57353b2ef244f2c1e392be500b7a9748b85efb06b8bec83c6ad2fc4a87c

See more details on using hashes here.

File details

Details for the file pylabeledrf-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: pylabeledrf-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.11.1 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.23.4 CPython/3.5.2

File hashes

Hashes for pylabeledrf-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d458b56986bdb92a617463e5fee2c8d6cde158cf82ebcc73c88d19afc3d7b018
MD5 faaf7cd085a729bedb1e128c7c14b68f
BLAKE2b-256 02d858fdb09e168466b6e97e3e375f9f76fc8dfdd358d27b1853a6ea51da19c1

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