I got it! And it looks lovely. Thanks so much Liam and Cecile.
Best,
Amanda
From: R-sig-phylo on behalf of Liam Revell
Sent: Saturday, March 9, 2019 9:42 AM
To: Cecile Ane; r-sig-phylo@r-project.org
Subject: Re: [R-sig-phylo] using color function
Cecile makes a good point. In this case if your tree has 36 edges all
you would have to do is change your code such that:
phylomorphospace(...,control=list(col.edge=setNames(1:36,tree$edge[,2])))
and you'll have the colors that correspond to the numeric vector 1:36.
(These are just the 8
colors can be numeric. for example:
plot(1:36, 1:36, col=1:36)
Cécile
On Mar 8, 2019, at 8:42 PM, Liam Revell
mailto:liam.rev...@umb.edu>> wrote:
Dear Amanda.
I'm a little confused by your code. If you want to use
control=list(col.edge) you need to set col.edge to a vector of colors,
but in
Dear Amanda.
I'm a little confused by your code. If you want to use
control=list(col.edge) you need to set col.edge to a vector of colors,
but in your example col.edge is a numeric vector from 1 to 36.
For your particular case, there is actually a much simpler way to set
all the edges in a