Merge branch 'master' of ssh://copper.broadinstitute.org/humgen/gsa-scr1/gsa-engineering/git/unstable
This commit is contained in:
commit
2125c4f38f
|
|
@ -134,7 +134,7 @@ public class VariantsToTable extends RodWalker<Integer, Integer> {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* By default, this tool throws a UserException when it encounters a field without a value in some record. This
|
* By default, this tool throws a UserException when it encounters a field without a value in some record. This
|
||||||
* is generally useful when you mistype -F CHROM, so that you get a friendly warning about CHRMO not being
|
* is generally useful when you mistype -F CHROM, so that you get a friendly warning about CHROM not being
|
||||||
* found before the tool runs through 40M 1000G records. However, in some cases you genuinely want to allow such
|
* found before the tool runs through 40M 1000G records. However, in some cases you genuinely want to allow such
|
||||||
* fields (e.g., AC not being calculated for filtered records, if included). When provided, this argument
|
* fields (e.g., AC not being calculated for filtered records, if included). When provided, this argument
|
||||||
* will cause VariantsToTable to write out NA values for missing fields instead of throwing an error.
|
* will cause VariantsToTable to write out NA values for missing fields instead of throwing an error.
|
||||||
|
|
@ -313,6 +313,7 @@ public class VariantsToTable extends RodWalker<Integer, Integer> {
|
||||||
getters.put("FILTER", new Getter() { public String get(VariantContext vc) {
|
getters.put("FILTER", new Getter() { public String get(VariantContext vc) {
|
||||||
return vc.isNotFiltered() ? "PASS" : Utils.join(",", vc.getFilters()); }
|
return vc.isNotFiltered() ? "PASS" : Utils.join(",", vc.getFilters()); }
|
||||||
});
|
});
|
||||||
|
getters.put("ID", new Getter() { public String get(VariantContext vc) { return vc.hasID() ? vc.getID() : "."; } });
|
||||||
getters.put("HET", new Getter() { public String get(VariantContext vc) { return Integer.toString(vc.getHetCount()); } });
|
getters.put("HET", new Getter() { public String get(VariantContext vc) { return Integer.toString(vc.getHetCount()); } });
|
||||||
getters.put("HOM-REF", new Getter() { public String get(VariantContext vc) { return Integer.toString(vc.getHomRefCount()); } });
|
getters.put("HOM-REF", new Getter() { public String get(VariantContext vc) { return Integer.toString(vc.getHomRefCount()); } });
|
||||||
getters.put("HOM-VAR", new Getter() { public String get(VariantContext vc) { return Integer.toString(vc.getHomVarCount()); } });
|
getters.put("HOM-VAR", new Getter() { public String get(VariantContext vc) { return Integer.toString(vc.getHomVarCount()); } });
|
||||||
|
|
|
||||||
|
|
@ -381,7 +381,8 @@ public abstract class AbstractVCFCodec implements FeatureCodec, NameAwareCodec,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
attributes.put(VariantContext.ID_KEY, id);
|
if ( ! id.equals(VCFConstants.EMPTY_ID_FIELD) )
|
||||||
|
attributes.put(VariantContext.ID_KEY, id);
|
||||||
return attributes;
|
return attributes;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue