These are chat archives for dereneaton/ipyrad

14th
Nov 2017
tommydevitt
@tommydevitt
Nov 14 2017 02:00 UTC
Thanks @dereneaton

Hi @dereneaton , I am trying to generate ABBA BABA results on my data. I have 14 species and a total of about 60 individuals. I am primarily interested in the relationships between species and not necessarily between each individuals. Maybe first, does that make sense? is it statistically correct?
I am using the generate_tests_from_tree function but to obtain a manageable number of tests I need to constrain a lot the tips (fixing p4, p3 and p2) and still I am getting 30 to 60 tests. Would there be a way to define the units (species) that I want to test without a priori defining their positions in the test (except for the outgroup). Maybe something like the imap dictionary defined in treemix?
Also I can run analyses when using an early diverging species as p3 but not when it's a more recently diverged lineage like in your case for 35855_rex and 40578_rex. Why is that?
The cookbooks are quite nice but where could I find the documentation about the different arguments available to run these tests?

Thanks

Deren Eaton
@dereneaton
Nov 14 2017 15:59 UTC
@joqb yes, of course. You can define the tests by hand, or use a for loop or function to create them. The .tests attribute of your baba object can be either a single dictionary or a list of dictionaries, where each dictionary is a different test that it will perform. The generate function is just meant to be a convenient way to generate many tests given a tree, but if you want to run a test that is not on the tree then you need to write it by hand:
## a single test
baba.tests = {
    "p4": ["32082_przewalskii", "33588_przewalskii"],
    "p3": ["29154_superba"], 
    "p2": ["33413_thamno"], 
    "p1": ["40578_rex"],
}

## multiple tests
bb.tests = [
    {
     "p4": ["32082_przewalskii", "33588_przewalskii"],
     "p3": ["41954_cyathophylloides"], 
     "p2": ["33413_thamno"], 
     "p1": ["40578_rex"],
    },
    {
     "p4": ["32082_przewalskii", "33588_przewalskii"],
     "p3": ["41478_cyathophylloides"], 
     "p2": ["33413_thamno"], 
     "p1": ["40578_rex"],
    },
]