Did I find the right examples for you? yes no

All Samples(26)  |  Call(16)  |  Derive(0)  |  Import(10)

src/c/o/cogent-1.5.3/cogent/app/pplacer.py   cogent(Download)
from os.path import splitext,abspath,join,split
from StringIO import StringIO
from cogent.parse.phylip import get_align_for_phylip
from cogent.parse.tree import DndParser
from cogent.core.tree import PhyloNode
    # convert aln to phy since seq_names need fixed to run through pplacer
 
    new_aln=get_align_for_phylip(StringIO(aln))
 
    # convert aln to fasta in case it is not already a fasta file

src/c/o/cogent-1.5.3/cogent/app/parsinsert.py   cogent(Download)
from cogent.core.alignment import SequenceCollection,Alignment
from os.path import splitext, join,abspath
from cogent.parse.phylip import get_align_for_phylip
from StringIO import StringIO
 
def insert_sequences_into_tree(aln, moltype, params={}):
    """Returns a tree from placement of sequences
    """
    # convert aln to phy since seq_names need fixed to run through parsinsert
    new_aln=get_align_for_phylip(StringIO(aln))

src/p/y/pycogent-HEAD/cogent/app/pplacer.py   pycogent(Download)
from os.path import splitext,abspath,join,split
from StringIO import StringIO
from cogent.parse.phylip import get_align_for_phylip
from cogent.parse.tree import DndParser
from cogent.core.tree import PhyloNode
    # convert aln to phy since seq_names need fixed to run through pplacer
 
    new_aln=get_align_for_phylip(StringIO(aln))
 
    # convert aln to fasta in case it is not already a fasta file

src/p/y/pycogent-HEAD/cogent/app/parsinsert.py   pycogent(Download)
from cogent.core.alignment import SequenceCollection,Alignment
from os.path import splitext, join,abspath
from cogent.parse.phylip import get_align_for_phylip
from StringIO import StringIO
 
def insert_sequences_into_tree(aln, moltype, params={}):
    """Returns a tree from placement of sequences
    """
    # convert aln to phy since seq_names need fixed to run through parsinsert
    new_aln=get_align_for_phylip(StringIO(aln))

src/c/o/cogent-1.5.3/tests/test_parse/test_phylip.py   cogent(Download)
#!/bin/env python
#file cogent/parse/test_phylip.py
"""Unit tests for the phylip parser
"""
from cogent.parse.phylip import MinimalPhylipParser, get_align_for_phylip
    def test_get_align(self):
        """get_align_for_phylip should return Aligment object for phylip files"""
        align = get_align_for_phylip(self.big_interleaved)
        align = get_align_for_phylip(self.interleaved_little)
        s = str(align)
GGCAGCCAATCACGGCAGCCAATCACGGCAGCCAATCAC
''')
        align = get_align_for_phylip(self.noninterleaved_little)
        s = str(align)
        self.assertEqual(s, '''>Archaeopt

src/p/y/pycogent-HEAD/tests/test_parse/test_phylip.py   pycogent(Download)
#!/bin/env python
#file cogent/parse/test_phylip.py
"""Unit tests for the phylip parser
"""
from cogent.parse.phylip import MinimalPhylipParser, get_align_for_phylip
    def test_get_align(self):
        """get_align_for_phylip should return Aligment object for phylip files"""
        align = get_align_for_phylip(self.big_interleaved)
        align = get_align_for_phylip(self.interleaved_little)
        s = str(align)
GGCAGCCAATCACGGCAGCCAATCACGGCAGCCAATCAC
''')
        align = get_align_for_phylip(self.noninterleaved_little)
        s = str(align)
        self.assertEqual(s, '''>Archaeopt

src/p/y/pycogent-HEAD/tests/test_app/test_raxml_v730.py   pycogent(Download)
                                   insert_sequences_into_tree)
from cogent.app.util import ApplicationError,get_tmp_filename
from cogent.parse.phylip import get_align_for_phylip
from cogent.core.tree import PhyloNode
from cogent.core.moltype import RNA,DNA
        self.test_model = "GTRCAT"
 
        self.align1 = get_align_for_phylip(StringIO(PHYLIP_FILE))
 
        self.test_fn1 = "/tmp/raxml_test1.txt"
        params["-m"] = 'GTRGAMMA'
 
        aln_ref_query=get_align_for_phylip(StringIO(PHYLIP_FILE_DNA_REF_QUERY))
        aln = Alignment(aln_ref_query)
        seqs, align_map = aln.toPhylip()

src/p/y/pycogent-HEAD/tests/test_app/test_raxml.py   pycogent(Download)
from cogent.app.raxml import Raxml,raxml_alignment, build_tree_from_alignment
from cogent.app.util import ApplicationError
from cogent.parse.phylip import get_align_for_phylip
from cogent.core.tree import PhyloNode
from cogent.core.moltype import RNA
        self.test_model = "GTRCAT"
 
        self.align1 = get_align_for_phylip(StringIO(PHYLIP_FILE))
 
        self.test_fn1 = "/tmp/raxml_test1.txt"

src/c/o/cogent-1.5.3/tests/test_app/test_raxml_v730.py   cogent(Download)
                                   insert_sequences_into_tree)
from cogent.app.util import ApplicationError,get_tmp_filename
from cogent.parse.phylip import get_align_for_phylip
from cogent.core.tree import PhyloNode
from cogent.core.moltype import RNA,DNA
        self.test_model = "GTRCAT"
 
        self.align1 = get_align_for_phylip(StringIO(PHYLIP_FILE))
 
        self.test_fn1 = "/tmp/raxml_test1.txt"
        params["-m"] = 'GTRGAMMA'
 
        aln_ref_query=get_align_for_phylip(StringIO(PHYLIP_FILE_DNA_REF_QUERY))
        aln = Alignment(aln_ref_query)
        seqs, align_map = aln.toPhylip()

src/c/o/cogent-1.5.3/tests/test_app/test_raxml.py   cogent(Download)
from cogent.app.raxml import Raxml,raxml_alignment, build_tree_from_alignment
from cogent.app.util import ApplicationError
from cogent.parse.phylip import get_align_for_phylip
from cogent.core.tree import PhyloNode
from cogent.core.moltype import RNA
        self.test_model = "GTRCAT"
 
        self.align1 = get_align_for_phylip(StringIO(PHYLIP_FILE))
 
        self.test_fn1 = "/tmp/raxml_test1.txt"