phykit 2.1.23__tar.gz → 2.1.26__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {phykit-2.1.23 → phykit-2.1.26}/PKG-INFO +1 -1
- {phykit-2.1.23 → phykit-2.1.26}/phykit/cli_registry.py +7 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/phykit.py +276 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/service_factories.py +3 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/__init__.py +3 -0
- phykit-2.1.26/phykit/services/tree/network_signal.py +684 -0
- phykit-2.1.26/phykit/services/tree/quartet_network.py +784 -0
- phykit-2.1.26/phykit/services/tree/relative_rate_test.py +399 -0
- phykit-2.1.26/phykit/version.py +1 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit.egg-info/PKG-INFO +1 -1
- {phykit-2.1.23 → phykit-2.1.26}/phykit.egg-info/SOURCES.txt +3 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit.egg-info/entry_points.txt +10 -0
- {phykit-2.1.23 → phykit-2.1.26}/setup.py +10 -0
- phykit-2.1.23/phykit/version.py +0 -1
- {phykit-2.1.23 → phykit-2.1.26}/LICENSE.md +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/README.md +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/__init__.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/__main__.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/errors.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/__init__.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/boolean_argument_parsing.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/caching.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/files.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/json_output.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/parallel.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/stats_summary.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/helpers/streaming.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/__init__.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/__init__.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/alignment_entropy.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/alignment_length.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/alignment_length_no_gaps.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/alignment_outlier_taxa.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/alignment_recoding.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/base.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/column_score.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/composition_per_taxon.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/compositional_bias_per_site.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/create_concatenation_matrix.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/dna_threader.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/evolutionary_rate_per_site.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/faidx.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/gc_content.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/mask_alignment.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/occupancy_per_taxon.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/pairwise_identity.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/parsimony_informative_sites.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/plot_alignment_qc.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/rcv.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/rcvt.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/rename_fasta_entries.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/sum_of_pairs_score.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/alignment/variable_sites.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/base.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/ancestral_reconstruction.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/base.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/bipartition_support_stats.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/branch_length_multiplier.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/collapse_branches.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/consensus_network.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/consensus_tree.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/cont_map.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/cophylo.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/covarying_evolutionary_rates.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/density_map.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/dvmc.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/evolutionary_rate.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/fit_continuous.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/hidden_paralogy_check.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/internal_branch_stats.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/internode_labeler.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/last_common_ancestor_subtree.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/lb_score.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/monophyly_check.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/nearest_neighbor_interchange.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/ou_shift_detection.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/ouwie.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/patristic_distances.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/phenogram.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/phylogenetic_glm.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/phylogenetic_ordination.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/phylogenetic_regression.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/phylogenetic_signal.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/phylomorphospace.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/polytomy_test.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/print_tree.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/prune_tree.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/rate_heterogeneity.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/rename_tree_tips.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/rf_distance.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/root_tree.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/saturation.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/spurious_sequence.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/stochastic_character_map.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/terminal_branch_stats.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/tip_labels.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/tip_to_tip_distance.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/tip_to_tip_node_distance.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/total_tree_length.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/treeness.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit/services/tree/treeness_over_rcv.py +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit.egg-info/dependency_links.txt +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit.egg-info/requires.txt +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/phykit.egg-info/top_level.txt +0 -0
- {phykit-2.1.23 → phykit-2.1.26}/setup.cfg +0 -0
|
@@ -109,6 +109,13 @@ ALIAS_TO_HANDLER: Dict[str, str] = {
|
|
|
109
109
|
"ou_shifts": "ou_shift_detection",
|
|
110
110
|
"l1ou": "ou_shift_detection",
|
|
111
111
|
"detect_shifts": "ou_shift_detection",
|
|
112
|
+
"quartet_net": "quartet_network",
|
|
113
|
+
"qnet": "quartet_network",
|
|
114
|
+
"nanuq": "quartet_network",
|
|
115
|
+
"netsig": "network_signal",
|
|
116
|
+
"net_signal": "network_signal",
|
|
117
|
+
"rrt": "relative_rate_test",
|
|
118
|
+
"tajima_rrt": "relative_rate_test",
|
|
112
119
|
"polyt_test": "polytomy_test",
|
|
113
120
|
"ptt": "polytomy_test",
|
|
114
121
|
"polyt": "polytomy_test",
|
|
@@ -232,6 +232,11 @@ class Phykit:
|
|
|
232
232
|
ou_shift_detection (alias: ou_shifts; l1ou; detect_shifts)
|
|
233
233
|
- automatic OU shift detection using LASSO
|
|
234
234
|
(Khabbazian et al. 2016)
|
|
235
|
+
quartet_network (alias: quartet_net; qnet; nanuq)
|
|
236
|
+
- quartet-based network inference (NANUQ-style)
|
|
237
|
+
distinguishing ILS from hybridization
|
|
238
|
+
network_signal (alias: netsig; net_signal)
|
|
239
|
+
- phylogenetic signal on a network
|
|
235
240
|
polytomy_test (alias: polyt_test; polyt; ptt)
|
|
236
241
|
- conducts a polytomy test using gene
|
|
237
242
|
support frequencies
|
|
@@ -239,6 +244,9 @@ class Phykit:
|
|
|
239
244
|
- prints ascii tree
|
|
240
245
|
prune_tree (alias: prune)
|
|
241
246
|
- prune taxa from a phylogeny
|
|
247
|
+
relative_rate_test (alias: rrt; tajima_rrt)
|
|
248
|
+
- Tajima's relative rate test for equal evolutionary
|
|
249
|
+
rates between two ingroup lineages
|
|
242
250
|
rename_tree_tips (alias: rename_tree; rename_tips)
|
|
243
251
|
- renames tips in a phylogeny according to a file with
|
|
244
252
|
the desired new tip names
|
|
@@ -3636,6 +3644,196 @@ class Phykit:
|
|
|
3636
3644
|
_add_json_argument(parser)
|
|
3637
3645
|
_run_service(parser, argv, ConsensusNetwork)
|
|
3638
3646
|
|
|
3647
|
+
@staticmethod
|
|
3648
|
+
def quartet_network(argv):
|
|
3649
|
+
parser = _new_parser(
|
|
3650
|
+
description=textwrap.dedent(
|
|
3651
|
+
f"""\
|
|
3652
|
+
{help_header}
|
|
3653
|
+
|
|
3654
|
+
Quartet-based network inference (NANUQ-style).
|
|
3655
|
+
|
|
3656
|
+
Computes quartet concordance factors from gene trees,
|
|
3657
|
+
classifies each quartet as tree-like, hybrid, or
|
|
3658
|
+
unresolved using two chi-squared tests (matching the
|
|
3659
|
+
NANUQ algorithm from MSCquartets), and optionally
|
|
3660
|
+
visualizes the result as a species tree with
|
|
3661
|
+
reticulation edges overlaid.
|
|
3662
|
+
|
|
3663
|
+
Star test: Pearson chi-squared against uniform (1/3
|
|
3664
|
+
each). If p > beta, the quartet is unresolved.
|
|
3665
|
+
Tree test (T3): G-test under the MSC tree model.
|
|
3666
|
+
If p > alpha, the quartet is tree-like.
|
|
3667
|
+
Otherwise the quartet shows hybrid signal.
|
|
3668
|
+
|
|
3669
|
+
Input can be either:
|
|
3670
|
+
1) a file with one Newick tree per line, or
|
|
3671
|
+
2) a file with one tree-file path per line.
|
|
3672
|
+
|
|
3673
|
+
Aliases:
|
|
3674
|
+
quartet_network, quartet_net, qnet, nanuq
|
|
3675
|
+
Command line interfaces:
|
|
3676
|
+
pk_quartet_network, pk_quartet_net, pk_qnet,
|
|
3677
|
+
pk_nanuq
|
|
3678
|
+
|
|
3679
|
+
Usage:
|
|
3680
|
+
phykit quartet_network -t/--trees <trees>
|
|
3681
|
+
[--alpha 0.05] [--beta 0.95]
|
|
3682
|
+
[--missing-taxa error|shared]
|
|
3683
|
+
[--plot-output <file>] [--json]
|
|
3684
|
+
|
|
3685
|
+
Options
|
|
3686
|
+
=====================================================
|
|
3687
|
+
-t/--trees file containing trees or
|
|
3688
|
+
tree paths
|
|
3689
|
+
|
|
3690
|
+
--alpha significance level for the
|
|
3691
|
+
T3 tree model test
|
|
3692
|
+
(Default: 0.05)
|
|
3693
|
+
|
|
3694
|
+
--beta threshold for the star tree
|
|
3695
|
+
test; quartets with
|
|
3696
|
+
p_star > beta are called
|
|
3697
|
+
unresolved
|
|
3698
|
+
(Default: 0.95)
|
|
3699
|
+
|
|
3700
|
+
--missing-taxa how to handle mismatched
|
|
3701
|
+
taxa across trees:
|
|
3702
|
+
error or shared
|
|
3703
|
+
(Default: error)
|
|
3704
|
+
|
|
3705
|
+
--plot-output output filename for the
|
|
3706
|
+
quartet network plot
|
|
3707
|
+
(optional)
|
|
3708
|
+
|
|
3709
|
+
--json optional argument to output
|
|
3710
|
+
results as JSON
|
|
3711
|
+
"""
|
|
3712
|
+
),
|
|
3713
|
+
)
|
|
3714
|
+
parser.add_argument("-t", "--trees", type=str, required=True, help=SUPPRESS)
|
|
3715
|
+
parser.add_argument(
|
|
3716
|
+
"--alpha",
|
|
3717
|
+
type=float,
|
|
3718
|
+
default=0.05,
|
|
3719
|
+
required=False,
|
|
3720
|
+
help=SUPPRESS,
|
|
3721
|
+
)
|
|
3722
|
+
parser.add_argument(
|
|
3723
|
+
"--beta",
|
|
3724
|
+
type=float,
|
|
3725
|
+
default=0.95,
|
|
3726
|
+
required=False,
|
|
3727
|
+
help=SUPPRESS,
|
|
3728
|
+
)
|
|
3729
|
+
parser.add_argument(
|
|
3730
|
+
"--missing-taxa",
|
|
3731
|
+
type=str,
|
|
3732
|
+
choices=["error", "shared"],
|
|
3733
|
+
default="error",
|
|
3734
|
+
required=False,
|
|
3735
|
+
help=SUPPRESS,
|
|
3736
|
+
)
|
|
3737
|
+
parser.add_argument(
|
|
3738
|
+
"--plot-output",
|
|
3739
|
+
type=str,
|
|
3740
|
+
default=None,
|
|
3741
|
+
required=False,
|
|
3742
|
+
help=SUPPRESS,
|
|
3743
|
+
)
|
|
3744
|
+
_add_json_argument(parser)
|
|
3745
|
+
_run_service(parser, argv, QuartetNetwork)
|
|
3746
|
+
|
|
3747
|
+
@staticmethod
|
|
3748
|
+
def network_signal(argv):
|
|
3749
|
+
parser = _new_parser(
|
|
3750
|
+
description=textwrap.dedent(
|
|
3751
|
+
f"""\
|
|
3752
|
+
{help_header}
|
|
3753
|
+
|
|
3754
|
+
Phylogenetic signal on a network.
|
|
3755
|
+
|
|
3756
|
+
Measures phylogenetic signal (Bloomberg's K and/or
|
|
3757
|
+
Pagel's lambda) on a phylogenetic network by
|
|
3758
|
+
incorporating hybrid edges inferred from quartet
|
|
3759
|
+
concordance factors.
|
|
3760
|
+
|
|
3761
|
+
Hybrid edges can be specified directly (--hybrid)
|
|
3762
|
+
or loaded from a quartet network JSON file
|
|
3763
|
+
(--quartet-json).
|
|
3764
|
+
|
|
3765
|
+
Aliases:
|
|
3766
|
+
network_signal, netsig, net_signal
|
|
3767
|
+
Command line interfaces:
|
|
3768
|
+
pk_network_signal, pk_netsig, pk_net_signal
|
|
3769
|
+
|
|
3770
|
+
Usage:
|
|
3771
|
+
phykit network_signal -t <tree> -d <trait_data>
|
|
3772
|
+
(--hybrid <P H1 H2 gamma> | --quartet-json <file>)
|
|
3773
|
+
[--method both|blombergs_k|lambda]
|
|
3774
|
+
[--permutations 1000] [-v/--verbose] [--json]
|
|
3775
|
+
|
|
3776
|
+
Options
|
|
3777
|
+
=====================================================
|
|
3778
|
+
-t/--tree a phylogeny file
|
|
3779
|
+
(required)
|
|
3780
|
+
|
|
3781
|
+
-d/--trait-data tab-delimited trait data
|
|
3782
|
+
file (required)
|
|
3783
|
+
|
|
3784
|
+
--hybrid hybrid specification:
|
|
3785
|
+
parent hybrid child1
|
|
3786
|
+
child2 gamma (nargs +)
|
|
3787
|
+
|
|
3788
|
+
--quartet-json path to quartet network
|
|
3789
|
+
JSON output file
|
|
3790
|
+
|
|
3791
|
+
--method which signal measure to
|
|
3792
|
+
compute: both, blombergs_k,
|
|
3793
|
+
or lambda
|
|
3794
|
+
(Default: both)
|
|
3795
|
+
|
|
3796
|
+
--permutations number of permutations
|
|
3797
|
+
for significance testing
|
|
3798
|
+
(Default: 1000)
|
|
3799
|
+
|
|
3800
|
+
-v/--verbose print detailed output
|
|
3801
|
+
|
|
3802
|
+
--json optional argument to output
|
|
3803
|
+
results as JSON
|
|
3804
|
+
"""
|
|
3805
|
+
),
|
|
3806
|
+
)
|
|
3807
|
+
parser.add_argument("-t", "--tree", type=str, required=True, help=SUPPRESS)
|
|
3808
|
+
parser.add_argument("-d", "--trait-data", type=str, required=True, help=SUPPRESS)
|
|
3809
|
+
hybrid_group = parser.add_mutually_exclusive_group(required=True)
|
|
3810
|
+
hybrid_group.add_argument(
|
|
3811
|
+
"--hybrid", nargs="+", type=str, help=SUPPRESS
|
|
3812
|
+
)
|
|
3813
|
+
hybrid_group.add_argument(
|
|
3814
|
+
"--quartet-json", type=str, help=SUPPRESS
|
|
3815
|
+
)
|
|
3816
|
+
parser.add_argument(
|
|
3817
|
+
"--method",
|
|
3818
|
+
type=str,
|
|
3819
|
+
choices=["both", "blombergs_k", "lambda"],
|
|
3820
|
+
default="both",
|
|
3821
|
+
required=False,
|
|
3822
|
+
help=SUPPRESS,
|
|
3823
|
+
)
|
|
3824
|
+
parser.add_argument(
|
|
3825
|
+
"--permutations",
|
|
3826
|
+
type=int,
|
|
3827
|
+
default=1000,
|
|
3828
|
+
required=False,
|
|
3829
|
+
help=SUPPRESS,
|
|
3830
|
+
)
|
|
3831
|
+
parser.add_argument(
|
|
3832
|
+
"-v", "--verbose", action="store_true", required=False, help=SUPPRESS
|
|
3833
|
+
)
|
|
3834
|
+
_add_json_argument(parser)
|
|
3835
|
+
_run_service(parser, argv, NetworkSignal)
|
|
3836
|
+
|
|
3639
3837
|
@staticmethod
|
|
3640
3838
|
def prune_tree(argv):
|
|
3641
3839
|
parser = _new_parser(
|
|
@@ -3693,6 +3891,72 @@ class Phykit:
|
|
|
3693
3891
|
_add_json_argument(parser)
|
|
3694
3892
|
_run_service(parser, argv, PruneTree)
|
|
3695
3893
|
|
|
3894
|
+
@staticmethod
|
|
3895
|
+
def relative_rate_test(argv):
|
|
3896
|
+
parser = _new_parser(
|
|
3897
|
+
description=textwrap.dedent(
|
|
3898
|
+
f"""\
|
|
3899
|
+
{help_header}
|
|
3900
|
+
|
|
3901
|
+
Tajima's relative rate test.
|
|
3902
|
+
|
|
3903
|
+
Tests whether two ingroup lineages evolve at
|
|
3904
|
+
equal rates relative to an outgroup. The tree
|
|
3905
|
+
must be rooted with a single outgroup taxon.
|
|
3906
|
+
All pairwise ingroup comparisons are performed
|
|
3907
|
+
with Bonferroni and BH-FDR correction.
|
|
3908
|
+
|
|
3909
|
+
Provide either a single alignment (-a) or a
|
|
3910
|
+
file listing multiple alignment paths (-l) for
|
|
3911
|
+
batch (multi-gene) analysis.
|
|
3912
|
+
|
|
3913
|
+
Aliases:
|
|
3914
|
+
relative_rate_test, rrt, tajima_rrt
|
|
3915
|
+
Command line interfaces:
|
|
3916
|
+
pk_relative_rate_test, pk_rrt, pk_tajima_rrt
|
|
3917
|
+
|
|
3918
|
+
Usage:
|
|
3919
|
+
phykit relative_rate_test (-a <alignment> | -l <alignment_list>) -t <tree> [-v/--verbose] [--json]
|
|
3920
|
+
|
|
3921
|
+
Options
|
|
3922
|
+
=====================================================
|
|
3923
|
+
-a/--alignment a single alignment file
|
|
3924
|
+
|
|
3925
|
+
-l/--alignment-list a file listing alignment
|
|
3926
|
+
paths (one per line)
|
|
3927
|
+
|
|
3928
|
+
-t/--tree a rooted tree file
|
|
3929
|
+
(required)
|
|
3930
|
+
|
|
3931
|
+
-v/--verbose print detailed output
|
|
3932
|
+
|
|
3933
|
+
--plot-output save pairwise p-value
|
|
3934
|
+
heatmap to this path
|
|
3935
|
+
|
|
3936
|
+
--json optional argument to output
|
|
3937
|
+
results as JSON
|
|
3938
|
+
"""
|
|
3939
|
+
),
|
|
3940
|
+
)
|
|
3941
|
+
aln_group = parser.add_mutually_exclusive_group()
|
|
3942
|
+
aln_group.add_argument(
|
|
3943
|
+
"-a", "--alignment", type=str, required=False, help=SUPPRESS, metavar=""
|
|
3944
|
+
)
|
|
3945
|
+
aln_group.add_argument(
|
|
3946
|
+
"-l", "--alignment-list", dest="alignment_list", type=str, required=False, help=SUPPRESS, metavar=""
|
|
3947
|
+
)
|
|
3948
|
+
parser.add_argument(
|
|
3949
|
+
"-t", "--tree", type=str, required=True, help=SUPPRESS, metavar=""
|
|
3950
|
+
)
|
|
3951
|
+
parser.add_argument(
|
|
3952
|
+
"-v", "--verbose", action="store_true", required=False, help=SUPPRESS
|
|
3953
|
+
)
|
|
3954
|
+
parser.add_argument(
|
|
3955
|
+
"--plot-output", type=str, required=False, help=SUPPRESS, metavar=""
|
|
3956
|
+
)
|
|
3957
|
+
_add_json_argument(parser)
|
|
3958
|
+
_run_service(parser, argv, RelativeRateTest)
|
|
3959
|
+
|
|
3696
3960
|
@staticmethod
|
|
3697
3961
|
def rename_tree_tips(argv):
|
|
3698
3962
|
parser = _new_parser(
|
|
@@ -4658,6 +4922,14 @@ def consensus_network(argv=None):
|
|
|
4658
4922
|
Phykit.consensus_network(sys.argv[1:])
|
|
4659
4923
|
|
|
4660
4924
|
|
|
4925
|
+
def quartet_network(argv=None):
|
|
4926
|
+
Phykit.quartet_network(sys.argv[1:])
|
|
4927
|
+
|
|
4928
|
+
|
|
4929
|
+
def network_signal(argv=None):
|
|
4930
|
+
Phykit.network_signal(sys.argv[1:])
|
|
4931
|
+
|
|
4932
|
+
|
|
4661
4933
|
def consensus_tree(argv=None):
|
|
4662
4934
|
Phykit.consensus_tree(sys.argv[1:])
|
|
4663
4935
|
|
|
@@ -4666,6 +4938,10 @@ def prune_tree(argv=None):
|
|
|
4666
4938
|
Phykit.prune_tree(sys.argv[1:])
|
|
4667
4939
|
|
|
4668
4940
|
|
|
4941
|
+
def relative_rate_test(argv=None):
|
|
4942
|
+
Phykit.relative_rate_test(sys.argv[1:])
|
|
4943
|
+
|
|
4944
|
+
|
|
4669
4945
|
def rename_tree_tips(argv=None):
|
|
4670
4946
|
Phykit.rename_tree_tips(sys.argv[1:])
|
|
4671
4947
|
|
|
@@ -75,6 +75,9 @@ RateHeterogeneity = _LazyServiceFactory("phykit.services.tree.rate_heterogeneity
|
|
|
75
75
|
FitContinuous = _LazyServiceFactory("phykit.services.tree.fit_continuous", "FitContinuous")
|
|
76
76
|
OUwie = _LazyServiceFactory("phykit.services.tree.ouwie", "OUwie")
|
|
77
77
|
OUShiftDetection = _LazyServiceFactory("phykit.services.tree.ou_shift_detection", "OUShiftDetection")
|
|
78
|
+
QuartetNetwork = _LazyServiceFactory("phykit.services.tree.quartet_network", "QuartetNetwork")
|
|
79
|
+
NetworkSignal = _LazyServiceFactory("phykit.services.tree.network_signal", "NetworkSignal")
|
|
80
|
+
RelativeRateTest = _LazyServiceFactory("phykit.services.tree.relative_rate_test", "RelativeRateTest")
|
|
78
81
|
PolytomyTest = _LazyServiceFactory("phykit.services.tree.polytomy_test", "PolytomyTest")
|
|
79
82
|
PrintTree = _LazyServiceFactory("phykit.services.tree.print_tree", "PrintTree")
|
|
80
83
|
PruneTree = _LazyServiceFactory("phykit.services.tree.prune_tree", "PruneTree")
|
|
@@ -18,6 +18,9 @@ _EXPORTS = {
|
|
|
18
18
|
"MonophylyCheck": "monophyly_check",
|
|
19
19
|
"NearestNeighborInterchange": "nearest_neighbor_interchange",
|
|
20
20
|
"PatristicDistances": "patristic_distances",
|
|
21
|
+
"QuartetNetwork": "quartet_network",
|
|
22
|
+
"NetworkSignal": "network_signal",
|
|
23
|
+
"RelativeRateTest": "relative_rate_test",
|
|
21
24
|
"PolytomyTest": "polytomy_test",
|
|
22
25
|
"PrintTree": "print_tree",
|
|
23
26
|
"PruneTree": "prune_tree",
|