Mycorrhiza population assignment tools.
Project description
Mycorrhiza
Combining phylogenetic networks and Random Forests for prediction of ancestry from multilocus genotype data.
Installing Mycorrhiza with pip
-
Make sure you have the latest version of Python 3.x
python --version -
Install pip
python -m pip install --upgrade pip setuptools wheel
-
Install Mycorrhiza
pip install --upgrade mycorrhiza
-
Install SplitsTree
Installation executables for SplitsTree4 can be found here.
Running an analysis
-
Import the necessary modules.
from mycorrhiza.dataset import Myco from mycorrhiza.analysis import CrossValidate from mycorrhiza.plotting.plotting import mixture_plot
-
(Optional) By default Mycorrhiza will look for SplitStree in your PATH. I you wish to specify a different path for the SplitsTree executable you can do so in the settings module.
from mycorrhiza.settings import const const['__SPLITSTREE_PATH__'] = 'SplitsTree'
-
Load some data. Here data is loaded in the Mycorrhiza format from the Gipsy moth sample data file. Example data can be found here.
myco = Myco(file_path='data/gipsy.myc') myco.load()
-
Run an analysis. Here a simple 5-fold cross-validation analysis is executed on all available loci, without partitioning.
cv = CrossValidate(dataset=myco, out_path='data/') cv.run(n_partitions=1, n_loci=0, n_splits=5, n_estimators=60, n_cores=1)
-
Plot the results.
mixture_plot(cv)
Documentation
https://jgeofil.github.io/mycorrhiza/
File formats
Myco
Diploid genotypes occupy 2 rows (the sample identifier must be identical).
| Column(s) | Content | Type |
|---|---|---|
| 1 | Sample identifier | string |
| 2 | Population | string or integer |
| 3 | Learning flag | {0,1} |
| 4 to M+3 | Loci | {A, T, G, C, N} |
STRUCTURE
Diploid genotypes occupy 2 rows (the sample identifier must be identical).
| Column(s) | Content | Type |
|---|---|---|
| 1 | Sample identifier | string |
| 2 | Population | integer |
| 3 | Learning flag | {0,1} |
| 4 to O+3 | Optional (Ignored) | |
| O+3 to M+O+3 | Loci | integer or -9 |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mycorrhiza-0.0.7.tar.gz.
File metadata
- Download URL: mycorrhiza-0.0.7.tar.gz
- Upload date:
- Size: 10.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d386f8e036d13d9eb054d5c094cb8b1107282dbf74394c6fd79fee99c760bd63
|
|
| MD5 |
d0a2099aa7434b4f6cdd5194d4458ace
|
|
| BLAKE2b-256 |
6d0953e084238c615fbe6c32ec59ba05ef1399f79c17c397d08c120fd0f36208
|
File details
Details for the file mycorrhiza-0.0.7-py3-none-any.whl.
File metadata
- Download URL: mycorrhiza-0.0.7-py3-none-any.whl
- Upload date:
- Size: 19.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e13bfd32f583d8aa322120c3bc73a9631ca02171a9c592ebb160b8f4217a0f43
|
|
| MD5 |
1518af50b4205383e286c1e7b1c2ea36
|
|
| BLAKE2b-256 |
615406acf356049e5f30a42e04bb222e62fd59526d7b60c730148e22d815c6f1
|