[R-sig-genetics] Hierfstat: calculating global Fst and CI

Vikram Chhatre crypticlineage at gmail.com
Fri Aug 5 18:14:36 CEST 2016


Hello,

I am trying to estimate global FST and 95% CI for a data set.  The original
data was imported as genind object and converted to hierfstat format using
genind2hierfstat() function.

To estimate CI, I did the following:

> library(hierfstat)
> trees.hf <- genind2hierfstat(trees.genind)
> df.bootfst <- boot.vc(trees.hf[,1], trees.hf[,-1], nboot=1000)

Error in 1:dim(data[dum, ])[1] : argument of length 0

The data formatting is not an issue because I was able to run
basic.stats(trees.hf) successfully. I have also tried specifying full
dimensions for the loci as follows without success:

> df.bootfst <- boot.vc(trees.hf[,1], trees.hf[,2:500], nboot=1000)

I get the same error when using the varcomp.glob() function.

Thank you for any help.

Vikram

	[[alternative HTML version deleted]]



More information about the R-sig-genetics mailing list