Learn R Programming

ape (version 5.8)

write.nexus: Write Tree File in Nexus Format

Description

This function writes trees in a file with the NEXUS format.

Usage

write.nexus(..., file = "", translate = TRUE)

Value

None (invisible `NULL').

Arguments

...

either (i) a single object of class "phylo", (ii) a series of such objects separated by commas, or (iii) a list containing such objects.

file

a file name specified by either a variable of mode character, or a double-quoted string; if file = "" (the default) then the tree is written on the standard output connection.

translate

a logical, if TRUE (the default) a translation of the tip labels is done which are replaced in the parenthetic representation with tokens.

Author

Emmanuel Paradis

Details

If several trees are given, they must all have the same tip labels.

If among the objects given some are not trees of class "phylo", they are simply skipped and not written in the file.

See write.tree for details on how tip (and node) labels are checked before being printed.

References

Maddison, D. R., Swofford, D. L. and Maddison, W. P. (1997) NEXUS: an extensible file format for systematic information. Systematic Biology, 46, 590--621.

See Also

read.nexus, read.tree, write.tree, read.nexus.data, write.nexus.data