Hello all,
I would like to remove any singletons/doubletons from my vcf file.
I can find all the singletons/doubletons using: vcftools --vcf file.vcf --singletons --out file
This output file.singletons which has this information:
CHROM POS SINGLETON/DOUBLETON ALLELE INDV
I thought I could extract the POS column from the file.singletons, remove the header and use as follow:
vcftools --vcf file.vcf --exclude file.singletons --recode --recode-INFO-all --out final_vcf
However this does not seem to remove any SNPs from the .vcf file. Is there anyway I can remove the SNPs listed in the .singletons file?
Thank you all for your help in advance
Just wanted to say thank you for following up like this! It helped me just now :)