Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PCA result of glPca is quite different from plink #327

Open
cpwater opened this issue Mar 15, 2022 · 1 comment
Open

PCA result of glPca is quite different from plink #327

cpwater opened this issue Mar 15, 2022 · 1 comment

Comments

@cpwater
Copy link

cpwater commented Mar 15, 2022

I tried to plot PCA result of glPca in adegenet and found that the result is quite different from that generated from plink. Anybody knows why?

For glPca, I ran this in R
pca_gl <- glPca(glFile_rmNA, useC = T, nf = 30)
scatter(pca_gl, clabel = 0)

And for plink, I ran this
plink --allow-extra-chr --threads 20 -bfile Call.vcf --pca 30 --out pca_plink
and the plot used PC1 and PC2 of the result.

Thanks so much and this is important to me!

glPca_raw
plink_raw

@zkamvar
Copy link
Collaborator

zkamvar commented Apr 20, 2022

I'm not familiar with how plink works. It might have to do with centering, scaling, or whether the genotypes or haplotypes are used as individual units.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants