Re: [R-sig-phylo] selecting terminal branch lengths?

2010-02-10 Thread Emmanuel Paradis
Liam Maria, Liam J. Revell wrote on 09/02/2010 04:24: Try this: # given an object of class phylo called tree # 1. create vector for terminal edge lengths terminal.edges-matrix(NA,length(tree$tip.label)); # 2. copy terminal branches into vector

[R-sig-phylo] selecting terminal branch lengths?

2010-02-08 Thread mgavil2
Dear All I am trying to find a way to get a vector of only the terminal branch length for species in a phylogeny, but cant seem to find a way any suggestions? Best, Maria Mercedes -- Maria Mercedes Gavilanez Department of Biological Sciences 107 Life Sciences Building Louisiana State

Re: [R-sig-phylo] selecting terminal branch lengths?

2010-02-08 Thread Liam J. Revell
Try this: # given an object of class phylo called tree # 1. create vector for terminal edge lengths terminal.edges-matrix(NA,length(tree$tip.label)); # 2. copy terminal branches into vector terminal.edges-tree$edge.length[tree$edge[1:(2*length(tree$tip.label)-2),2]=length(tree$tip.label)];