Hi,
I'm trying to use aboot with the WardD2 method and a custom IBS matrix as distance.
Therefore:
1) I've used the DART package to create the function for the IBS distance, which requires the genelight input format and creates a "dist" object as output.
2) I used this function in the aboot analysys but I've this error:
"Starting Error in cat("Starting", funname, "\n") :
argument 2 (type 'language') cannot be handled by 'cat'"
Here is my script
library("poppr")
library("dartR")
data("nancycats")
nancy_light<-gi2gl(nancycats, parallel = FALSE, verbose = NULL)
wardd2 <- function(d) ape::as.phylo(hclust(as.dist(d), method = "ward.D2"))
ibs_dist<- function(i) (dartR::gl.grm(dartR::gi2gl(i), plotheatmap = F, verbose = NULL))
tree <- aboot(nancycats, cutoff = 0, tree="wardd2", quiet = TRUE, sample = 100, distance = ibs_dist)
Thank you in advance,
Chiara.