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

How to convert a VCF file to a this format? #219

Open
guojingfang123 opened this issue Jan 16, 2020 · 1 comment
Open

How to convert a VCF file to a this format? #219

guojingfang123 opened this issue Jan 16, 2020 · 1 comment

Comments

@guojingfang123
Copy link

Hi, I only have VCF files now, how can I change it to the format "master_pinus_data_genotype.txt"? Are there tools or scripts? Thank you.

@zkamvar
Copy link
Contributor

zkamvar commented Jan 16, 2020

Hello,

If you have VCF data, {pegas} can import it with read.vcf: https://www.rdocumentation.org/packages/pegas/versions/0.12/topics/read.vcf, which gets stored as a "loci" object. You can also use {vcfR} with read.vcrR: https://www.rdocumentation.org/packages/vcfR/versions/1.8.0/topics/VCF%20input%20and%20output and then you can use vcfr2genind to import your data to genind format: https://knausb.github.io/vcfR_documentation/export_genind_genclone.html

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