Closed courtiol closed 3 years ago
Thanks! I modified your fix a bit: Fst is NA in this case, as you suggested, and the same for Fit (or maybe we should have Fit = Fis since T = S in this case?)
Note that you have very close results with:
R> h <- H(jaguar_corridor, observed = TRUE)
R> 1 - h[, 2] / h[, 1]
FCA742 FCA723 FCA740 FCA441 FCA391 F98 F53
0.16360294 0.41176471 0.04811715 0.29824561 0.20454545 0.02506964 0.30000000
F124 F146 F85 F42 FCA453 FCA741
0.01209677 0.28753181 0.18018018 0.28037383 0.24951267 0.29824561
This PR attempts at making Fst() run, even when a single population is provided as input:
Please double check that the patch does not mess up the computation. Perhaps the NaN should be also be replaced by NAs.