Add sequence dropout rate to metadata output

This commit is contained in:
eugenefischer
2022-09-30 00:33:41 -05:00
parent b9b13fb75e
commit b8aeeb988f
2 changed files with 7 additions and 2 deletions

View File

@@ -15,6 +15,7 @@ public class GraphWithMapData implements java.io.Serializable {
private final Integer[] wellPopulations; private final Integer[] wellPopulations;
private final int alphaCount; private final int alphaCount;
private final int betaCount; private final int betaCount;
private final double dropoutRate;
private final int readDepth; private final int readDepth;
private final double readErrorRate; private final double readErrorRate;
private final double errorCollisionRate; private final double errorCollisionRate;
@@ -30,7 +31,7 @@ public class GraphWithMapData implements java.io.Serializable {
public GraphWithMapData(SimpleWeightedGraph graph, Integer numWells, Integer[] wellConcentrations, public GraphWithMapData(SimpleWeightedGraph graph, Integer numWells, Integer[] wellConcentrations,
Map<String, String> distCellsMapAlphaKey, Integer alphaCount, Integer betaCount, Map<String, String> distCellsMapAlphaKey, Integer alphaCount, Integer betaCount,
Integer readDepth, Double readErrorRate, Double errorCollisionRate, Double dropoutRate, Integer readDepth, Double readErrorRate, Double errorCollisionRate,
Double realSequenceCollisionRate, Duration time){ Double realSequenceCollisionRate, Duration time){
// Map<Integer, Integer> plateVtoAMap, // Map<Integer, Integer> plateVtoAMap,
@@ -49,6 +50,7 @@ public class GraphWithMapData implements java.io.Serializable {
// this.plateBtoVMap = plateBtoVMap; // this.plateBtoVMap = plateBtoVMap;
// this.alphaWellCounts = alphaWellCounts; // this.alphaWellCounts = alphaWellCounts;
// this.betaWellCounts = betaWellCounts; // this.betaWellCounts = betaWellCounts;
this.dropoutRate = dropoutRate;
this.readDepth = readDepth; this.readDepth = readDepth;
this.readErrorRate = readErrorRate; this.readErrorRate = readErrorRate;
this.errorCollisionRate = errorCollisionRate; this.errorCollisionRate = errorCollisionRate;
@@ -127,4 +129,6 @@ public class GraphWithMapData implements java.io.Serializable {
} }
public Double getRealSequenceCollisionRate() { return realSequenceCollisionRate; } public Double getRealSequenceCollisionRate() { return realSequenceCollisionRate; }
public Double getDropoutRate() { return dropoutRate; }
} }

View File

@@ -136,7 +136,7 @@ public class Simulator implements GraphModificationFunctions {
Duration time = Duration.between(start, stop); Duration time = Duration.between(start, stop);
//create GraphWithMapData object //create GraphWithMapData object
GraphWithMapData output = new GraphWithMapData(graph, numWells, samplePlate.getPopulations(), distCellsMapAlphaKey, GraphWithMapData output = new GraphWithMapData(graph, numWells, samplePlate.getPopulations(), distCellsMapAlphaKey,
alphaCount, betaCount, readDepth, readErrorRate, errorCollisionRate, realSequenceCollisionRate, time); alphaCount, betaCount, samplePlate.getError(), readDepth, readErrorRate, errorCollisionRate, realSequenceCollisionRate, time);
//Set source file name in graph to name of sample plate //Set source file name in graph to name of sample plate
output.setSourceFilename(samplePlate.getFilename()); output.setSourceFilename(samplePlate.getFilename());
//return GraphWithMapData object //return GraphWithMapData object
@@ -305,6 +305,7 @@ public class Simulator implements GraphModificationFunctions {
Map<String, String> metadata = new LinkedHashMap<>(); Map<String, String> metadata = new LinkedHashMap<>();
metadata.put("sample plate filename", data.getSourceFilename()); metadata.put("sample plate filename", data.getSourceFilename());
metadata.put("sequence dropout rate", data.getDropoutRate().toString());
metadata.put("graph filename", dataFilename); metadata.put("graph filename", dataFilename);
metadata.put("MWM algorithm type", algoType); metadata.put("MWM algorithm type", algoType);
metadata.put("matching weight", totalMatchingWeight.toString()); metadata.put("matching weight", totalMatchingWeight.toString());