Tuesday, March 8, 2011

Significant updates: phylomorphospace()

I just made a few significant updates to my function to create the phylomorphospace() plots of Sidlauskas (2008). This new version can be downloaded from my R phylogenetics page (direct link to code here).

First, I removed the requirement that the user provide a matrix of the estimated states at internal nodes of the tree. Now, if this is left out the function will simply use the {ape} function ace() to estimate these values using maximum likelihood.

Second, I liked the appearance of Luke's ecomorph plot a lot, so I decided to make a slightly modified version of this design the default for the function. This means that internal nodes are small filled circles, and terminal nodes are larger filled circles (although I did not use the same size disparity as in Luke's plot - see below). In addition, plotting tip labels is now optional and can be turned off by setting label=FALSE.

Finally, third, I added some basic error checking to make the function less buggy.

Feedback welcome!

[Click on image for a higher quality version.]


  1. That first update was buggy, but I just fixed it (I hope).

  2. Mauricio Torres-MejiaAugust 17, 2011 at 5:01 PM

    Hey Liam, I used your phylomorphospace function with the function world of the package maps to plot a phylogeny in the world map. Longitude and latitude were used as x and y variables. The location of the ancestral nodes maybe is not correct, but the map is useful to show the spatial distribution of tips. Thanks for making your function available!

  3. Very cool. If you would like to share this (at any point), I would like to post it on the blog.


Note: due to the very large amount of spam, all comments are now automatically submitted for moderation.