Hi,
In my VCF files, the NS field (Number of Samples With Data) is entirely missing. I would like to get this number so I can filter SNPs based on % of individuals with missing data.
I am using mpileup on 100 individuals of a population, followed by bcf to vcf conversion.
$ samtools-0.1.19/samtools mpileup -B -uD -Q 20 -f reference.fa Ind1.sorted.bam Ind2.sorted.bam [...] Ind100.sorted.bam | bcftools view -bvcg - > SNP.bcf
followed by
$ samtools-0.1.19/bcftools/bcftools view SNP.bcf | vcfutils.pl varFilter -D 5000 > SNP.vcf
The vcf file version is 4.1
Any help would be greatly appreciated. Thanks.
Edit: This is what I get under 'INFO' column:
DP=143;QS=0.897417,0.102583,0.000000,0.000000;VDB=6.988258e-06;RPB=5.927889e+00;AF1=0.09297;AC1=26;DP4=2,127,0,13;MQ=29;FQ=999;PV4=1,0.0071,1,1
In my VCF files, the NS field (Number of Samples With Data) is entirely missing. I would like to get this number so I can filter SNPs based on % of individuals with missing data.
I am using mpileup on 100 individuals of a population, followed by bcf to vcf conversion.
$ samtools-0.1.19/samtools mpileup -B -uD -Q 20 -f reference.fa Ind1.sorted.bam Ind2.sorted.bam [...] Ind100.sorted.bam | bcftools view -bvcg - > SNP.bcf
followed by
$ samtools-0.1.19/bcftools/bcftools view SNP.bcf | vcfutils.pl varFilter -D 5000 > SNP.vcf
The vcf file version is 4.1
Any help would be greatly appreciated. Thanks.
Edit: This is what I get under 'INFO' column:
DP=143;QS=0.897417,0.102583,0.000000,0.000000;VDB=6.988258e-06;RPB=5.927889e+00;AF1=0.09297;AC1=26;DP4=2,127,0,13;MQ=29;FQ=999;PV4=1,0.0071,1,1