|
__init__(self,
input=None)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature |
source code
|
|
|
get_original_taxon_order(self)
Included for backwards compatibility. |
source code
|
|
|
set_original_taxon_order(self,
value)
Included for backwards compatibility. |
source code
|
|
|
read(self,
input)
Read and parse NEXUS imput (filename, file-handle, string. |
source code
|
|
|
_get_nexus_block(self,
file_contents)
Generator for looping through Nexus blocks. |
source code
|
|
|
_unknown_nexus_block(self,
title,
contents) |
source code
|
|
|
_parse_nexus_block(self,
title,
contents)
Parse a known Nexus Block |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_check_taxlabels(self,
taxon)
Check for presence of taxon in self.taxlabels. |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
_utree(self,
options)
Some software (clustalx) uses 'utree' to denote an unrooted tree. |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_get_indices(self,
options,
set_type=' chars ' ,
separator=' = ' )
Parse the taxset/charset specification '1 2 3 - 5 dog cat 10 - 20
\ 3' --> [0,1,2,3,4,'dog','cat',9,12,15,18] |
source code
|
|
|
_name_n_vector(self,
opts,
separator=' = ' )
Extract name and check that it's not in vector format. |
source code
|
|
|
_parse_list(self,
options_buffer,
set_type)
Parse a NEXUS list: [1, 2, 4-8\2, dog, cat] --> [1,2,4,6,8,17,21],
(assuming dog is taxon no. |
source code
|
|
|
_resolve(self,
identifier,
set_type=None)
Translate identifier in list into character/taxon index. |
source code
|
|
|
|
|
|
|
|
|
|
|
write_nexus_data_partitions(self,
matrix=None,
filename=None,
blocksize=None,
interleave=False,
exclude=[ ] ,
delete=[ ] ,
charpartition=None,
comment='
' ,
mrbayes=False)
Writes a nexus file for each partition in charpartition. |
source code
|
|
|
write_nexus_data(self,
filename=None,
matrix=None,
exclude=[ ] ,
delete=[ ] ,
blocksize=None,
interleave=False,
interleave_by_partition=False,
comment=None,
omit_NEXUS=False,
append_sets=True,
mrbayes=False,
codons_block=True)
Writes a nexus file with data and sets block to a file or handle. |
source code
|
|
|
append_sets(self,
exclude=[ ] ,
delete=[ ] ,
mrbayes=False,
include_codons=True,
codons_only=False)
Returns a sets block |
source code
|
|
|
export_fasta(self,
filename=None,
width=70)
Writes matrix into a fasta file: (self, filename=None, width=70). |
source code
|
|
|
export_phylip(self,
filename=None)
Writes matrix into a fasta file: (self, filename=None, width=70). |
source code
|
|
|
constant(self,
matrix=None,
delete=[ ] ,
exclude=[ ] )
Return a list with all constant characters. |
source code
|
|
|
|
|
|
|
crop_matrix(self,
matrix=None,
delete=[ ] ,
exclude=[ ] )
Return a matrix without deleted taxa and excluded characters. |
source code
|
|
|
bootstrap(self,
matrix=None,
delete=[ ] ,
exclude=[ ] )
Return a bootstrapped matrix. |
source code
|
|
|
add_sequence(self,
name,
sequence)
Adds a sequence to the matrix. |
source code
|
|
|
insert_gap(self,
pos,
n=1,
leftgreedy=False)
Add a gap into the matrix and adjust charsets and partitions. |
source code
|
|
|
_adjust_charlabels(self,
exclude=None,
insert=None)
Return adjusted indices of self.charlabels if characters are excluded
or inserted. |
source code
|
|
|
invert(self,
charlist)
Returns all character indices that are not in charlist. |
source code
|
|
|
gaponly(self,
include_missing=False)
Return gap-only sites. |
source code
|
|
|
|
Inherited from object :
__delattr__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__str__
|