Entering edit mode
2.7 years ago
arya.sagittarius
▴
10
I'm using the following to extract regions of a sample in the genome vcf file from gnomad. But im unable to extract the unique regions. is there a way to get the unique region?
tabix -h -R bedfile.bed gnomad.genomes.v3.2.1.hgdp_tgp.chr1.vcf.bgz | perl vcftools -c samplename > out.vcf
what is a "unique region" ?
by unique i meant the same as what bedtools -u option does i.e to report atleast one overlap
that's still not clear to me. Give us an example.
1) tabix -h -R bedfile.bed gnomad.genomes.v3.2.1.hgdp_tgp.chr1.vcf.bgz | perl vcftools -c samplename > out.vcf
I am using the above command to extract a certain region from "bedfile.bed" and pipe it to obtain the required sample from the vcf file using vcftools.
After this step im using the below command just to extract the unique regions, because Step1) give me same positions repeatedly. I just want the unique overlap.But even after running command 2) im getting the same results. Im unable to get the unique ones. So i was wondering what could be the reson for the same and also a wrok around to obtain the unique regions
2) bedtools/intersectBed -u --header -a file1.vcf -b bedfile.bed > output.vcf