-
Notifications
You must be signed in to change notification settings - Fork 23
make gnotate
make-gnotate
is used to create new gnotation
(zip) files to be used by slivar
.
Usage is mostly straight-forward. For example, to create the gnomad*.zip files, we use something like:
slivar make-gnotate \
--field AF_POPMAX:gnomad_popmax_af \
--field Hom:gnomad_nhomalt \
--prefix gnomad.hg38 \
gnomad.exomes.r2.0.1.sites.GRCh38.noVEP.norm.bcf \
gnomad.genomes.r2.0.1.sites.GRCh38.noVEP.norm.bcf
which takes the AF_POPMAX
and Hom
fields from the genomes and exomes VCFs and names them gnomad_popmax_af
and gnomad_nhomalt
respectively. These names (following the ':') should be chosen carefully as they will be the field added to the INFO whenever this is used as an annotator.
The resulting file will be gnomad.hg38.zip
In some cases, we may want to modify a field before adding it to the VCF. We can do this with --expr
s which are any javascript expressions that return a float. For example to get a spliceai annotation that reports the max value for any of the 4 splicing metrics, we can do:
slivar make-gnotate \
--message "spliceai annotations for academic use only." \
--expr "spliceai:Math.max(INFO.DS_AG, INFO.DS_AL, INFO.DS_DG, INFO.DS_DL)" \
--field spliceai \
--prefix spliceai \
exome_splice_ai.vcf.gz
Here, we use an expr
ession to take the max value of DS_AG
, DS_AL
, DS_DG
, and DS_DL
and put them into a new field named 'spliceai". Then we extract spliceai
and add it to the zip under that name.
The message added to the zip file will be printed each time this zip file is used to gnotate
a query VCF.