{
String type = SequenceOntologyI.SEQUENCE_VARIANT;
+ /*
+ * could we associate Consequence data with this allele and feature (transcript)?
+ * if so, prefer the consequence term from that data
+ */
if (csqAlleleFieldIndex == -1) // && snpEffAlleleFieldIndex == -1
{
/*
return type;
}
- /*
- * can we associate Consequence data with this allele and feature (transcript)?
- * if so, prefer the consequence term from that data
- */
if (consequence != null)
{
String[] csqFields = consequence.split(PIPE_REGEX);
}
/*
+ * filter out fields we don't want to capture
+ */
+ if (!vcfFieldsOfInterest.contains(key))
+ {
+ continue;
+ }
+
+ /*
* we extract values for other data which are allele-specific;
* these may be per alternate allele (INFO[key].Number = 'A')
* or per allele including reference (INFO[key].Number = 'R')
String myConsequence)
{
Object value = variant.getAttribute(CSQ_FIELD);
- // TODO if CSQ not present, try ANN (for SnpEff consequence data)?
if (value == null || !(value instanceof List<?>))
{