Hi Jorge, I find that this happens most often when I forget to set the row names of data. Try rownames(data) and if they're not the tip labels, then that's your problem.
Graham --------------------------------------------------------------------------- ------ Graham Slater Peter Buck Post-Doctoral Fellow Department of Paleobiology National Museum of Natural History The Smithsonian Institution [NHB, MRC 121] P.O. Box 37012 Washington DC 20013-7012 (202) 633-1316 slat...@si.edu <https://legacy.si.edu/owa/redir.aspx?C=HcyfurW5xkyXw2bWu-Td5xmRPtn7-c9I1lX iVWbeJqzfhgybLjvFBckclIN237FXoGKsGXlPAGg.&URL=mailto%3aSlaterG%40si.edu> www.fourdimensionalbiology.com <https://legacy.si.edu/owa/redir.aspx?C=HcyfurW5xkyXw2bWu-Td5xmRPtn7-c9I1lX iVWbeJqzfhgybLjvFBckclIN237FXoGKsGXlPAGg.&URL=http%3a%2f%2fwww.eeb.ucla.edu %2fgslater> On 10/22/13 9:05 AM, "Jorge Sanchez Gutierrez" <jorgesgutier...@unex.es> wrote: >Hi all, > >I am trying to use the geiger¹s treedata function to compare and match >the taxa in >my data and tree as follows: > >X <- treedata(tr, data) > >where ³tr² is the tree and ³data² is the matrix. However, the tips are >not found in >the data and are subsequently dropped from the tree, getting a tree with >0 tips. >Does anyone have any idea what might be wrong with this? > >I also tried this: > >X <- data[tr$tip.label,] which also should drop all the rows of data that >are not in >tr, however, I get an empty matrix. > >Thanks in advance for any help! > > >Jorge S. Gutierrez >Conservation Biology Research Group >Department of Anatomy, Cell Biology and Zoology >Faculty of Sciences >University of Extremadura >Badajoz 06006 >Spain > >_______________________________________________ >R-sig-phylo mailing list - R-sig-phylo@r-project.org >https://stat.ethz.ch/mailman/listinfo/r-sig-phylo >Searchable archive at >http://www.mail-archive.com/r-sig-phylo@r-project.org/ _______________________________________________ R-sig-phylo mailing list - R-sig-phylo@r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-phylo Searchable archive at http://www.mail-archive.com/r-sig-phylo@r-project.org/