Skip to content

Commit

Permalink
whoops
Browse files Browse the repository at this point in the history
  • Loading branch information
davidbenjamin committed May 16, 2024
1 parent 31f3f2b commit 065b347
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ static double[] getGermlineAltAlleleFrequencies(final List<Allele> allAlleles, f
List<OptionalInt> germlineIndices = GATKVariantContextUtils.alleleIndices(allAlleles, germlineVC.getAlleles());
final List<Double> germlineAltAFs = Mutect2Engine.getAttributeAsDoubleList(germlineVC, VCFConstants.ALLELE_FREQUENCY_KEY, afOfAllelesNotInGermlineResource);

for (int alleleIndex = 0; alleleIndex < allAlleles.size(); alleleIndex++) {
for (int alleleIndex = 1; alleleIndex < allAlleles.size(); alleleIndex++) { // start at 1 to skip the reference, which doesn't have an AF annotation
final Allele allele = allAlleles.get(alleleIndex);
// note the -1 since germlineAltAFs do not include ref
germlineIndices.get(alleleIndex).ifPresent(germlineIndex -> alleleFrequencies.put(allele, germlineAltAFs.get(germlineIndex - 1)));
Expand Down

0 comments on commit 065b347

Please sign in to comment.