Skip to content

Commit 413825d

Browse files
committed
Add detail to Plink/KING output
1 parent de48ea3 commit 413825d

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/variant/PlinkPcaStep.java

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,17 @@ private void runBatch(File inputVCF, File outputDirectory, VariantProcessingStep
228228
throw new PipelineJobException("Unable to find expected file: " + outputFile);
229229
}
230230

231+
String description = null;
232+
if (kingCutoff != null)
233+
{
234+
long includedIds = SequencePipelineService.get().getLineCount(new File(outputFile.getParentFile(), "plink.king.cutoff.in.id")) - 1;
235+
long excludedIds = SequencePipelineService.get().getLineCount(new File(outputFile.getParentFile(), "plink.king.cutoff.out.id")) - 1;
236+
237+
description = String.format("KING cutoff: %f, included IDs: %d, excluded IDs: %d", kingCutoff, includedIds, excludedIds);
238+
}
239+
231240
output.addOutput(outputFile, "PLink PCA");
232-
output.addSequenceOutput(outputFile, "PLink PCA for: " + inputVCF.getName() + (setName == null ? "" : ", for: " + setName), "PLink PCA", null, null, genome.getGenomeId(), null);
241+
output.addSequenceOutput(outputFile, "PLink PCA for: " + inputVCF.getName() + (setName == null ? "" : ", for: " + setName), "PLink PCA", null, null, genome.getGenomeId(), description);
233242
}
234243

235244
@Override

0 commit comments

Comments
 (0)