Package org.snpsift

Class SnpSiftCmdVcfOperator

  • All Implemented Interfaces:
    org.snpeff.snpEffect.commandLine.CommandLine, org.snpeff.snpEffect.VcfAnnotator

    public class SnpSiftCmdVcfOperator
    extends SnpSift
    Annotate a field based on an operation (max, min, etc.) of other VCF fields
    Author:
    pcingola
    • Field Detail

      • fields

        protected java.lang.String fields
      • outField

        protected java.lang.String outField
      • infoFields

        protected java.lang.String[] infoFields
    • Constructor Detail

      • SnpSiftCmdVcfOperator

        public SnpSiftCmdVcfOperator()
      • SnpSiftCmdVcfOperator

        public SnpSiftCmdVcfOperator​(java.lang.String[] args)
    • Method Detail

      • annotate

        public boolean annotate​(org.snpeff.vcf.VcfEntry vcfEntry)
        Specified by:
        annotate in interface org.snpeff.snpEffect.VcfAnnotator
        Overrides:
        annotate in class SnpSift
      • applyOp

        public java.lang.Double applyOp​(java.util.List<java.lang.Double> vals)
      • getArgs

        public java.lang.String[] getArgs()
        Specified by:
        getArgs in interface org.snpeff.snpEffect.commandLine.CommandLine
        Overrides:
        getArgs in class SnpSift
      • getValues

        public java.util.List<java.lang.Double> getValues​(org.snpeff.vcf.VcfEntry vcfEntry)
      • getValues

        public java.util.List<java.lang.Double> getValues​(org.snpeff.vcf.VcfEntry vcfEntry,
                                                          java.lang.String field)
        Parse an INFO field (can be multiple valued) and return a list of Double
      • headers

        protected java.util.List<org.snpeff.vcf.VcfHeaderEntry> headers()
        Description copied from class: SnpSift
        Headers to add
        Overrides:
        headers in class SnpSift
      • initialValue

        protected double initialValue()
      • parseArgs

        public void parseArgs​(java.lang.String[] args)
        Description copied from class: SnpSift
        Parse command line arguments
        Specified by:
        parseArgs in interface org.snpeff.snpEffect.commandLine.CommandLine
        Overrides:
        parseArgs in class SnpSift
      • run

        public boolean run()
        Annotate
        Specified by:
        run in interface org.snpeff.snpEffect.commandLine.CommandLine
        Overrides:
        run in class SnpSift
      • run

        public java.util.List<org.snpeff.vcf.VcfEntry> run​(boolean createList)
        Run filter
        Parameters:
        createList - : If true, create a list with the results. If false, show results on STDOUT
        Returns:
        If 'createList' is true, return a list containing all vcfEntries that passed the filter. Otherwise return null.
      • usage

        public void usage​(java.lang.String msg)
        Description copied from class: SnpSift
        Show usage message
        Specified by:
        usage in interface org.snpeff.snpEffect.commandLine.CommandLine
        Overrides:
        usage in class SnpSift