Did I find the right examples for you? yes no

All Samples(22)  |  Call(20)  |  Derive(0)  |  Import(2)

src/p/h/phylonetwork-1.0b6/src/phylonetwork/generators.py   phylonetwork(Download)
from .classes import PhyloTree 
from .operations import push_and_hang,hold_and_hang,push_and_label,hold_and_label
from .utils import random_weighted
from .memoize import memoize_function
from random import randint, shuffle
    n=len(taxa)
    if n==1:
        yield PhyloTree(eNewick=('%s;' % taxa[0]))
        return
    taxon=taxa[-1]
    n = len(taxa)
    if n == 1:
        return PhyloTree(eNewick=('%s;' % taxa[0]),id_offset=id_offset)
    parent = random_tree_bin_nont_global(taxa[0:-1],id_offset)
    u = random.choice(parent.nodes())
        return None
    if n==1:
        return PhyloTree(eNewick=('%s;' % taxa[0]),id_offset=id_offset)
    choices = {
        (push_and_hang,l-1,N-2,'nodes') : (N-2)*number_of_trees_nobin_nont_partial(n-1,l-1,N-2),
    n = len(taxa)
    if n == 1:
        return PhyloTree(eNewick=('%s;' % taxa[0]),id_offset=id_offset)
    choices = {
        N : number_of_trees_nobin_nont_partial(n,n,N) for N in range(n+1,2*n)

src/p/h/PhyloNetworks-HEAD/src/phylonetwork/generators.py   PhyloNetworks(Download)
from .classes import PhyloTree 
from .operations import push_and_hang,hold_and_hang,push_and_label,hold_and_label
from .utils import random_weighted
from .memoize import memoize_function
from random import randint, shuffle
    n=len(taxa)
    if n==1:
        yield PhyloTree(eNewick=('%s;' % taxa[0]))
        return
    taxon=taxa[-1]
    n = len(taxa)
    if n == 1:
        return PhyloTree(eNewick=('%s;' % taxa[0]),id_offset=id_offset)
    parent = random_tree_bin_nont_global(taxa[0:-1],id_offset)
    u = random.choice(parent.nodes())
        return None
    if n==1:
        return PhyloTree(eNewick=('%s;' % taxa[0]),id_offset=id_offset)
    choices = {
        (push_and_hang,l-1,N-2,'nodes') : (N-2)*number_of_trees_nobin_nont_partial(n-1,l-1,N-2),
    n = len(taxa)
    if n == 1:
        return PhyloTree(eNewick=('%s;' % taxa[0]),id_offset=id_offset)
    choices = {
        N : number_of_trees_nobin_nont_partial(n,n,N) for N in range(n+1,2*n)