.summary,ftype="off",lwd=1,cex=c(0.7,0.4))
map.summary$ace ## probabilities at nodes
All the best, Liam
Liam J. Revell
Associate Professor, University of Massachusetts Boston
Profesor Asistente, Universidad Católica de la Ssma Concepción
web: http://faculty.umb.edu/liam.revell/, http:/
changes, but ancestral states are the same.)
I hope this is helpful. All the best, Liam
Liam J. Revell
Associate Professor, University of Massachusetts Boston
Profesor Asistente, Universidad Católica de la Ssma Concepción
web: http://faculty.umb.edu/liam.revell/, http://www.phytools.org
Academic Direct
will be increased for more
realistic birth-death trees (in which there are more shorter branches
towards to tips of the tree).
Thanks! - Liam
Liam J. Revell
Department of Organismic and Evolutionary Biology
Harvard University
web: http://anolis.oeb.harvard.edu/~liam/
email: lrev...@fas.harvard.edu
Liam J. Revell
Department of Organismic and Evolutionary Biology
Harvard University
web: http://anolis.oeb.harvard.edu/~liam/
email: lrev...@fas.harvard.edu
On Mon, 18 May 2009, jeremy.beaul...@yale.edu wrote:
Hi all~
I was just wondering if there is a package or function in R that can simulate
the direction of
subtraction is arbitrary..., so only standard deviations are needed.
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev...@nescent.org
On Tue, 15 Sep 2009, Manabu Sakamoto wrote:
Dear list,
I am trying to standardise
,scaled=FALSE,var.contrasts=TRUE)
cont.x-cont.X[,1]/sqrt(cont.X[,2])
you will get the same vector of contrasts as you would obtain with:
cont.x-pic(x,tree)
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev...@nescent.org
Manabu Sakamoto
, however, diagnostic tests on contrasts usually use
absolute values (or squares) of contrasts. In general, these should not
be used in statistical analyses such as correlation (although positivized
contrasts may be used with no ill effect).
- Liam
Liam J. Revell
NESCent, Duke University
web
(birthdeath.tree(1,0, taxa.stop=11),11)));
This seems to work.
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev...@nescent.org
Santiago Claramunt wrote:
Hi all,
I'm having problems computing the inverse of the expected
variance-covariance
regression
for binary dependent variables. Systematic Biology (Advance Access).
URL: http://sysbio.oxfordjournals.org/cgi/content/abstract/syp074v1.
Others on this list-serve might also be well suited to comment on this
paper method.
Sincerely, Liam
Liam J. Revell
NESCent, Duke University
web
Thanks. That is very helpful information, actually!
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu
NEW email: lrev...@nescent.org
-Original Message-
From: Emmanuel Paradis emmanuel.para...@mpl.ird.fr
Sent: Monday, January 04, 2010 7:51 AM
To: Liam J
(edge=edge,tip.label=tip.label,edge.length=edge.length,Nnode=Nnode);
class(obj) - phylo;
obj-collapse.singles(obj);
obj;
}
I hope this works!
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev...@nescent.org
Timothee POISOT wrote
convenient form, from which:
results-as.matrix(results[,,1]);
puts all the results from all 10 simulations into one numspecies x 10
matrix.
Good luck!
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev...@nescent.org
Alexandre Antonelli wrote
)];
# 3. label terminal branches by tip label
names(terminal.edges)-tree$tip.label;
I think that should work.
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev...@nescent.org
mgavil2 wrote:
Dear All
I am trying to find a way to get a vector
a-solve(t(ones)%*%solve(sig2*C)%*%ones)%*%t(ones)%*%solve(sig2*C)%*%x;
# estimate ancestor
logL--(1/2)*(t(x-ones%*%a)%*%solve(sig2*C)%*%(x-ones%*%a))-(n/2)*log(2*pi)-(1/2)*log(det(sig2g*C));
# compute the log-likelihood
Hope this is helpful!
- Liam
Liam J. Revell
NESCent, Duke University
web
then that obtained
for every last one of your simulated datasets, then the P-value will be
entirely determined by the number of simulations that are used (as Luke
says). This seems to be case for your data (not surprising given the
very large values for F that were obtained).
- Liam
Liam J
)
# for instance
There are also several other related transformations, such as
lambdaTree() and deltaTree. These can be reviewed by querying:
?ouTree
Hope this is of some help.
Sincerely, Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev
:
# conducts BM simulation by ascending through the tree from the root
node to the tips
# by Liam J. Revell
sim.bm-function(tree,bm.rate,root.state){
# generate random normal deviates
dev-rnorm(n=length(tree$edge.length))
# give them appropriate variances
dev-dev*sqrt(bm.rate*tree
, but in case not - I thought I
would pass it along.
- Liam
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
email: lrev...@nescent.org, (new) liam.rev...@umb.edu
(new) blog: http://phytools.blogspot.com
On 12/29/2010 12:42 PM, Steve L wrote:
I've tried plotting
.
p.s - the tree is attached.
Chris
___
R-sig-phylo mailing list
R-sig-phylo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
--
Liam J. Revell
NESCent, Duke University
web: http://anolis.oeb.harvard.edu/~liam/
NEW email: lrev
it out.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://www.bio.umb.edu/facstaff/faculty_Revell.html
(new) email: liam.rev...@umb.edu
(new) blog: http://phytools.blogspot.com
On 2/17/2011 12:22 PM, pasquale.r...@libero.it wrote:
Hi all,
to feed Dave's questions; I have
://anolis.oeb.harvard.edu/~liam/R-phylogenetics/anc.trend/v0.1/anc.trend.R):
# written by Liam J. Revell 2011
anc.trend-function(phy,x,maxit=2000){
# preliminaries
# require dependencies
require(ape)
# set global
tol-1e-8
# compute C
D-dist.nodes(phy
to this issue beyond what I am able to offer.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://www.bio.umb.edu/facstaff/faculty_Revell.html
(new) email: liam.rev...@umb.edu
(new) blog: http://phytools.blogspot.com
On 2/22/2011 5:31 AM, Popko Wiersma wrote:
Dear all,
Can
, and then use di2multi().
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
(new) email: liam.rev...@umb.edu
(new) blog: http://phytools.blogspot.com
On 3/3/2011 3:12 PM, sd...@duke.edu wrote:
I have had similar challenges with going back and forth
$tip.label[-match(species.to.keep[,1],
tree$tip.label)])
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
(new) email: liam.rev...@umb.edu
(new) blog: http://phytools.blogspot.com
On 3/4/2011 6:52 AM, Eugen Egorov wrote:
First of all, thank you
not anticipate
this. To get around it, just do:
pruned.tree-drop.tip(tree,tree$tip.label[-na.omit(match(species.to.keep[,1],tree$tip.label))])
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
(new) email: liam.rev...@umb.edu
(new) blog
just bounce back any
phenotypes that exceed the lower or upper boundary conditions specified
by the user (by default they are -Inf and Inf). I think I did this
properly. Feedback welcome though.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell
object. This is stored as
phy$Aparam$nlea for phylog object phy. Unfortunately, it seems like
newick2phylog() is very slow for large trees.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
of nodes, but I was not able
to get this to work.]
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 3/17/2011 10:51 AM, Thierry Janssens - TNW wrote:
Dear R-sig-phylo,
I am looking
Dan is right on - and I also suspect that the issue of the non-rotating
node is probably due to a polytomy at that node.
Thanks for the insight Dan.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
the score for
parts of the tree that don't change among a set of trees - instead of
recalculating it each time anew. That I don't know.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
))
trees[[i]]-bind.tree(tree,new.tip,where=tree$edge[i,2],position=0.5)
# now plot them to see what we have done
plot(trees,type=unrooted,use.edge.length=F)
Of course I would be happy to see a more elegant solution!
Sincerely, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http
=((George,Paul),(Ringo,John));)
trees-add.everywhere(tree,Pete_Best)
plot(trees,type=unrooted)
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 4/1/2011 11:33 PM, Liam J. Revell wrote:
Hi
this, but if you already have the object
in memory, you can write it to file and then read it back in using
read.dna(...,as.character=T), as above.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
# now bind tr1 to tr2, where it was removed
tr.bound-bind.tree(tr2,tr1,where=which(tr2$tip.label==NA))
# now plot, to visualize the result
plot(tree); x11(); plot(tr.bound)
Thanks. - Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev
would be fairly simple using equations 15
of Ives et al., I think (I will do this when I get a chance); adding the
latter not so much. I believe Tony Ives may have MATLAB code that does
this already. Maybe he can comment.
I hope this is somewhat helpful.
Sincerely, Liam
--
Liam J. Revell
Hi Vanderlei,
Try this which uses ape function prop.part():
temp-prop.part(tree)
X-matrix(0,nrow=length(tree$tip),ncol=length(temp),dimnames=list(tree$tip.label,tree$node.label))
for(i in 1:ncol(X)) X[temp[[i]],i]-1
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http
0.005683385
7,1 0.516492136
7,8 0.761613776
8,2 0.714302898
8,3 0.071461088
6,4 0.217680734
6,5 0.393926894
You can easily see that they are the same branch lengths as in our
original tree.
I hope this is helpful.
Sincerely, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http
Sorry, I didn't see that this had already been addressed.
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 5/17/2011 12:39 PM, David Bapst wrote:
Alanna-
It's because when multi2di
Hi Alanna,
You can get this kind of error if your tree has tip edges with zero
length. Then C-vcv.phylo(tree) will be exactly singular. Could this
be true of your tree?
Best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev
not have
this issue.
Good luck.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 5/18/2011 3:50 AM, Annemarie Verkerk wrote:
Hi all,
I’m having some trouble with the function
,x,method=lambda,test=TRUE)
Best of luck.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 5/23/2011 2:46 PM, Carl Boettiger wrote:
Hi Annemarie,
No problem, tried to give some
resolve
our multifurcating tree after we attached the extra tip).
Hope this helps.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 6/30/2011 12:40 PM, ppi...@uniroma3.it wrote
J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 7/11/2011 10:44 PM, wrote:
dear all,
I have a question when I used the pic funtion, it appeared an
error:'phy' is not rooted and fully
here as if smdata is a
data frame, then smdata[,1] does not inherit the rownames of smdata and
pic() will return an incorrect set of contrasts.)
I hope this helps. No doubt other subscribers to the list may have
something to add.
Best, Liam
--
Liam J. Revell
University of Massachusetts
(given a set value of lambda) is just:
mat.lambda-lambda*(mat-diag(diag(mat)))+diag(diag(mat))
I'm not sure whether or not this is exactly what you're looking for, but
I hope it helps.
Best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email
This is implemented in my phytools package. This is not yet on CRAN,
but can be downloaded from
http://anolis.oeb.harvard.edu/~liam/R-phylogenetics/. The function is
ltt(). It is slow, but seems to work. Please let me know if you have
success with this.
- Liam
--
Liam J. Revell
the
differences in maximum ages!
Cheers,
Rob
On 11 August 2011 14:05, Liam J. Revell liam.rev...@umb.edu
mailto:liam.rev...@umb.edu wrote:
Hi Rob.
I can reproduce your error, but I haven't figured out the problem yet.
You can try an earlier version of this function, which seems to work
as the mean or median; as well as HPD intervals and ESSs
using, for instance, the MCMC diagnostics package coda.)
I hope this is helpful. Thanks again for giving the method a try.
Please don't hesitate to contact me for further clarification.
Best of luck.
- Liam
--
Liam J. Revell
) on this tree (and any star tree).
I hope this is helpful. Sorry for the slow reply.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 8/12/2011 1:35 AM, Manabu
()
tree-acctran(tree,dna)
I hope this helps.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 9/2/2011 8:35 AM, Velzen, Robin van wrote:
Dear R-sig phylo list members,
I am
labels 8 9, just as
we see with:
plot(tre); nodelabels()
I hope this clears things up somewhat.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 9/9/2011 7:51 AM
if you just label the nodes as they are first encountered in
the matrix this would be in the order of a post-order traversal of the tree.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 10/11/2011 6:18 PM, Antigoni Kaliontzopoulou wrote:
Hello everyone,
I am studying a binomial trait across a phylogeny and I'm trying
,tr2)
# plot the full tree
plot(tr3)
I hope this is kind of what you are going for.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 10/13/2011 5:32 PM, Scott
500 is tipward of 174 in the
tree, to re-root the tree halfway along the edge leading to node number
500 (in tree$edge), you would just do:
rooted.tree-reroot(tree,node.number=500,position=tree$edge.length[tree$edge[,2]==500]/2)
I think.
All the best, Liam
--
Liam J. Revell
University
; or,
better yet, Stone 2011, Syst. Biol. doi:10.1093/sysbio/syq098.)
Regarding extinction probability, perhaps someone else on the list can
address that specific example.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email
(which could be
interpreted as a test for departure from BM). This can be done by using
fitContinuous(...,model=lambda) and fitContinuous(...,model=BM), and then
comparing the likelihoods.
I hope this is helpful. Liam
Liam J. Revell
University of Massachusetts Boston
web: http
regression of Ives Garland (2009), but I'm not too familiar
with this method.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 11/14/2011 3:54 PM, David Bapst wrote:
Liam
,full=anc.nodes)[c(1:n,anc.nodes*(n+2:tree$Nnode)),c(1:n,anc.nodes*(n+2:tree$Nnode))]
C-matrix(h[M],nrow(M),ncol(M))
if(anc.nodes)
rownames(C)-colnames(C)-c(tree$tip.label,n+2:tree$Nnode)
else rownames(C)-colnames(C)-tree$tip.label
return(C)
}
All the best. - Liam
--
Liam J. Revell
: evol.vcv).
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 12/14/2011 3:26 PM, Theodore Garland Jr wrote:
Why not just include an interaction term between your main
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 12/26/2011 6:27 PM, Bruno de Medeiros wrote:
Hi everyone,
I am simulating characters evolving in a phylogetic tree under a number of
models
:
p2
10 sequences with 5 character and 5 different site patterns.
The states are 0 1
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 1/9/2012 9:14 AM, J Greenwood wrote:
Hi all,
I am
caper:pgls
r2-pgls(y~x,data=comparative.data(tree,data,Species),lambda=ML)
# fit using phytools:phyl.resid
r3-phyl.resid(tree,x,y,method=lambda)
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
particular direction.
If you share your tree and data I would be happy to look at the issue
more closely.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 1/19
be changed to
o-match(rownames(td$data),rownames(meserr))
meserr-as.matrix(meserr[o,])
because the former inadvertently converts meserr to a vector, when a
matrix is subsequently needed.
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 2/8/2012 1:59 PM, Amy Boddy wrote:
Hello,
I was wondering if somebody could help me with a problem I am having in
APE. I want
to the same rescaled data!
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 2/11/2012 10:20 AM, Pascal Title wrote:
Hello all
I am trying to calculate sigma2 values
] Chlorocebus pygerythrus
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 2/20/2012 7:30 PM, Graham Slater wrote:
Hi Tom,
have you tried running
name.check(t.100species
Hi Rafael.
I don't want to speak on behalf of the authors who are also on this
list, but OUwie can read in modified phylo objects created by the
phytools functions read.simmap make.simmap.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu
,function(a,x,sp)
ace(x,a)$ace[as.character(findMRCA(a,sp))],x=x,sp=sp)
Or, of course, you could just as easily use a simple for loop.
Perhaps this helps?
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog
Looks like this may be because your row names in your data frame have
spaces, while your tree tip labels do not.
Try:
rownames(example)-sub( ,,rownames(example))
example-example[tree$tip.label,]
Help?
- Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu
means for
each factor) and standard errors. These can be used to conduct posthoc
comparison of means using t-tests in the standard way.
I hope this helps.
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
[,1]
# replace NA with mean variance
xvar[is.na(xvar)]-mean(xvar,na.rm=TRUE)
# get the N per species
n-as.vector(table(names(y)))
# compute the standard errors
se-sqrt(xvar/n)
# compute K
K-phylosig(tree,xbar,se=se)
Hopefully that works for you.
All the best, Liam
--
Liam J. Revell
University
the analysis.
You might also get this error (or one quite similar) if you tree has
zero-length terminal edges or y=k*x for non-zero scalar constant k
(i.e., r(x,y)==1 or -1).
All the best, Liam
--
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email
matrix
# is a scalar constant
- Liam
--
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 7/13/2012 1:32 PM, Jonathan Mitchell wrote:
Hello all,
I'm trying
to compare to Ives Garland's MATLAB code I would
love to hear the result as I only hope I got this right.
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
Hi Andrew.
For desired correlation r, size data x, and tree you could just do:
library(phytools)
y-r*x+sqrt(1-r^2)*fastBM(tree)
This should give you the correlation r on average and the y|x should be
Brownian. (If x is Brownian, then both y x y|x will be too.)
- Liam
Liam J. Revell
Actually, modify my previous email. That only works for sig^2(x)=1.0. It
should be:
library(phytools)
y-r*x+sqrt(1-r^2)*fastBM(tree,sig2=mean(pic(x,tree)^2))
- Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email
Hi Ben.
Take a look at the function findMRCA in my package, phytools. I think this does
what you want.
Good luck. Liam
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
-Original
your tree has no edge lengths
plotTree(tree,fsize=0.2,ftype=i,lwd=0.4,pts=F)
savePlot(test2.pdf,type=pdf)
In addition, in an interactive session the tree (but not the labels)
will automatically resize when you manually resize the plotting window.
Is this at all helpful?
All the best, Liam
Liam J
tree$edge.length[tree$edge.length1]-2
tree$edge.length
plot(tree)
I hope this is of some help.
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
Hi. Try:
diag(vcv.phylo(tree))
nodeHeights in phytools will also give you a matrix with all the heights of
internal and terminal nodes in the same order as tree$edge.
- Liam
Liam J. Revell
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
a different rate of evolution than the rest of the tree, you could do
this as follows:
library(phytools) # load phytools
tree-make.era.map(tree,c(0,max(nodeHeights(tree))-3.4))
plotSimmap(tree,pts=F,lwd=3) # visualize
fit-brownie.lite(tree,x) # fit model
That's it. Good luck. Liam
Liam J. Revell
of brownie.lite in one of
its functions.
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://phytools.blogspot.com
On 9/18/2012 4:08 PM, Agus Camacho wrote:
Dear
Hi Agus.
I think the problem is that c() concatenates your data for the
continuous dependent variables in your model into one long vector. Try
instead:
table-as.matrix(table)
Y-cbind(table[,2],table[,3])
x-as.factor(table[,1])
phy.manova(tree,Y,x)
Good luck. - Liam
Liam J. Revell
with links to the code, on my blog:
http://blog.phytools.org/2012/11/function-to-break-up-plotted-tree-into.html
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http
with
generic functions such as summary residuals. (With the *possible*
exception that phyl.resid seems to be a little bit faster on large
trees. pgls in caper, for instance, took more than 4 min. to run a tree
of 1000 tips on my computer.)
I hope this helps.
All the best, Liam
Liam J. Revell
found via trial
error that:
plot(bird.orders,x.lim=c(1.3,35.5),y.lim=c(1.5,22.4),no.margin=T)
got me pretty darn close.
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog
-1,foo(tree,V)))
P-mean(abs(r.null)=abs(r))
return(list(beta=beta,r=r,P=P,method=method))
}
Perhaps this is a good idea. I don't know. All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev
I did a little further exploration of this proposed method - the
results discussion are here:
http://blog.phytools.org/2013/03/investigating-whether-rate-of-one.html
Maybe this will be of some help in deciding the best approach to go
forward with.
All the best, Liam
Liam J. Revell
(i.e., the rate of evolution in y,
sensu O'Meara et al. 2006 and other refs).
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://blog.phytools.org
On 3/15/2013 7
,colnames)))
XX-matrix(NA,length(aa),length(bb),dimnames=list(aa,bb))
for(i in 1:length(YY)) XX[rownames(YY[[i]]),colnames(YY[[i]])]-YY[[i]]
at least.
Hope this is helpful. Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell
the marginal or joint
reconstructions instead).
2) Extracting only the most likely state as *the* ancestral state at the
node ignores the uncertainty of our estimate. Really we have a
probability distribution for the states at each node.
- Liam
Liam J. Revell, Assistant Professor of Biology
as ancestral state estimates (except at the root).
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://blog.phytools.org
On 3/20/2013 6:02 PM, Liam J. Revell wrote
for
the subtree, not marginal ancestral state reconstructions. I believe
that the help page for ace will be clarified in future versions of ape.
Good luck. Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev
that seems reasonable to you.
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://blog.phytools.org
On 4/2/2013 7:27 PM, Vladimir Minin wrote:
Hi Liam,
When you say I
isn't working because your species names are
not row names in your data matrix. To have that, you could do:
birddata-read.csv(H:/birddata_family_20130405.csv,header=T,row.names=1)
All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http
that they can be easily aggregated
across mappings.
Good luck. All the best, Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://blog.phytools.org
On 4/5/2013 6:13 PM, Martin Turcotte
two traits; Threshml can
analyze more than two traits - but I believe is still limited to binary
discrete characters. Please let me know if it would be helpful to your
research to extend threshBayes to allow for multistate (ordered,
naturally) discrete characters.
All the best, Liam
Liam J
). - Liam
Liam J. Revell, Assistant Professor of Biology
University of Massachusetts Boston
web: http://faculty.umb.edu/liam.revell/
email: liam.rev...@umb.edu
blog: http://blog.phytools.org
On 4/8/2013 8:27 PM, Liam J. Revell wrote:
Hi Peter.
I'm not sure if this is what you mean, but Felsenstein
1 - 100 of 409 matches
Mail list logo