[Phylobase-devl] nTips method defined where?

Thibaut Jombart jombart at biomserv.univ-lyon1.fr
Thu May 22 10:31:14 CEST 2008


Aaron Mackey wrote:
>
> When reading a nexml-formatted tree with reticulated nodes (i.e. a 
> network), I'm getting an error while constructing the phylo4 tree that 
> the number of tips doesn't match the number of tip labels.  This is 
> stemming from check_phylo4, which checks that nTips(object) is equal 
> to length(tip.label) -- but I can't find the code for nTips (here is a 
> snippet of my debugging session within check_phylo4; there are only 5 
> tips, but nTips reports 6):
>
> Browse[1]> nTips(object)
> [1] 6
> Browse[1]> object at tip.label
> [1] "Homo sapiens" "t3"           "t2"           "t5"           
> "t4"         
> Browse[1]> getMethod("nTips", where=object)
> Method Definition:
>
> function (x, ...)
> {
>     .local <- function (x)
>     {
>         if (class(x) == "phylo") {
>             Ntip(x)
>         }
>         else stop(paste("no 'nTips' method available for", 
> deparse(substitute(x)),
>             "(class", class(x), ")"))
>     }
>     .local(x, ...)
> }
> <environment: 0x861e04c>
>
> Signatures:
>         x   
> target  "ANY"
> defined "ANY"
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Phylobase-devl mailing list
> Phylobase-devl at lists.r-forge.r-project.org
> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/phylobase-devl
>   
Hi,

nTips is defined in method-phylo4.R, at the begining of the file.

Best,

Thibaut.

-- 
######################################
Thibaut JOMBART
CNRS UMR 5558 - Laboratoire de Biométrie et Biologie Evolutive
Universite Lyon 1
43 bd du 11 novembre 1918
69622 Villeurbanne Cedex
Tél. : 04.72.43.29.35
Fax : 04.72.43.13.88
jombart at biomserv.univ-lyon1.fr
http://biomserv.univ-lyon1.fr/%7Ejombart/
http://adegenet.r-forge.r-project.org/


More information about the Phylobase-devl mailing list