Method: Bio::Nexus::TaxaBlock#to_nexus
- Defined in:
- lib/bio/db/nexus.rb
#to_nexus ⇒ Object
Returns a String describing this block as nexus formatted data.
- Returns
-
String
862 863 864 865 866 867 868 869 870 871 872 |
# File 'lib/bio/db/nexus.rb', line 862 def to_nexus line_1 = String.new line_1 << DIMENSIONS if ( Nexus::Util::larger_than_zero( get_number_of_taxa ) ) line_1 << " " << NTAX << "=" << get_number_of_taxa end line_1 << DELIMITER line_2 = String.new line_2 << TAXLABELS << " " << Nexus::Util::array_to_string( get_taxa ) << DELIMITER Nexus::Util::to_nexus_helper( TAXA_BLOCK, [ line_1, line_2 ] ) end |