This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Vcftools gives error when extracting snps

Hi,

I want to extract SNPs from vcf based on list of rsids. From this I used command vcftools --vcf <vcf_file> --snps <rsID_filename> --recode --recode-INFO-all

But it is giving me error.

stat error: No such file or directory
Error: Can't determine file type of --recode-INFO-all

Please tell me how to correct it.

vcftools snp

this cannot be the command you used. This is just the synopsis. What is the command you typed in the terminal.

vcftools --vcf <Simon.dbsnp.annotated.vcf> --snps <RSIDs.txt> --recode --recode-INFO-all

This is the command I typed on terminal.

1 answer

You know < and > redirect input and output? Why don't you try the same command without them?

vcftools --vcf Simon.dbsnp.annotated.vcf --snps RSIDs.txt --recode --recode-INFO-all

I tried it and it worked. Thanks

Log in to answer this question.