Comments (8)
I'm puzzled, it does for me? (see below). Could you provide an example?
> library(hierfstat)
> data(gtrunchier)
> pairwise.WCfst(gtrunchier[,-2])
1 2 3 4
1 NA 0.4695425 0.4194788 0.4486061
2 0.4695425 NA 0.7795719 0.7648904
3 0.4194788 0.7795719 NA 0.6321912
4 0.4486061 0.7648904 0.6321912 NA
5 0.3356973 0.5994008 0.5688411 0.5199231
6 0.3992087 0.7563057 0.5308519 0.4776794
5 6
1 0.3356973 0.3992087
2 0.5994008 0.7563057
3 0.5688411 0.5308519
4 0.5199231 0.4776794
5 NA 0.5065197
6 0.5065197 NA
> genet.dist(gtrunchier[,-2],method="WC84")
1 2 3 4 5
2 0.4695425
3 0.4194788 0.7795719
4 0.4486061 0.7648904 0.6321912
5 0.3356973 0.5994008 0.5688411 0.5199231
6 0.3992087 0.7563057 0.5308519 0.4776794 0.5065197
from hierfstat.
do you add the [, -2] to remove the population column?
from hierfstat.
Also, in the genet.dist option I used a genind object. When changed to hierfstat it works, but I thought it also did with genind (it does actually provide a result but it is different)
from hierfstat.
gtuncatula contains 2 populations column (hierarchical design), the [,-2] is just to remove one of them. With nancycats, the following give me TRUE:
all.equal(mat2vec(pairwise.WCfst(genind2hierfstat(nancycats))),mat2vec(as.matrix(genet.dist(nancycats,method="WC84"))))
from hierfstat.
Note that if you update hierfstat with the current version on github, you won't need the extra genind2hierfstat
in pairwise.WCfst
(see #56)
from hierfstat.
The new version is not on cran yet right?
Thank you for the answers
from hierfstat.
no, on github
from hierfstat.
Ok, the problem was that the version on cran for some reason was doing something odd with the genind (it did not return error though). With the github version it works.
from hierfstat.
Related Issues (20)
- Calculating FST with Dosage and Missing Data HOT 5
- plot boot.ppfst HOT 4
- Conversion genind to hierfstat df a little inconsistent HOT 2
- allelic.richness rounded numbers HOT 3
- problem performing sex.biased.test() function HOT 3
- `basic.stats` Ho calculation is actually allele frequency HOT 4
- boot.ppfst throwing an error with "diploid=F" HOT 4
- Fis calculations in basic.stats and boot.ppfis differ HOT 4
- NeiFST_calcuation_error HOT 2
- How to Interpret Negative Fsts HOT 2
- Basic Stats (and Ho/Hs/Fis) Require Population Name to be Numeric With A Single Population HOT 4
- pairwise.WCfst Error - non-conformable arrays HOT 3
- non-numeric argument error in boot.ppfis HOT 5
- Treatment of populations of 1 HOT 10
- NaN as result of basic.stats calculations for small populations HOT 2
- plotting the kinship matrix and printing it HOT 3
- boot.ppfst HOT 6
- no issue. Structure output is correct, two rows/individual. HOT 1
- Negative kinship values with beta.dosage? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hierfstat.