Changeset 4287
- Timestamp:
- Feb 13, 2012, 5:18:13 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/plugin/src/org/proteios/plugins/FeatureComparison.java
r4286 r4287 193 193 String currentAcc = ""; 194 194 boolean conflict = false; 195 float[] values = null;195 Float[] values = null; 196 196 writer 197 197 .println("Cluster ID\tPeptide Sequence\tExternal IDs\tCharge\tAverage RT"); … … 204 204 printRow(writer, values, currentCluster, currentSequence, 205 205 currentAcc, currentCharge, rtSum, nValues, conflict); 206 values = new float[entries];206 values = new Float[entries]; 207 207 conflict = false; 208 208 currentAcc = ""; … … 232 232 conflict = true; 233 233 } 234 values[msFiles.indexOf(feature.getMsFile())] += feature 235 .getIntegratedIntensity().floatValue(); 234 if (values[msFiles.indexOf(feature.getMsFile())] == null) 235 { 236 values[msFiles.indexOf(feature.getMsFile())] = feature 237 .getIntegratedIntensity(); 238 } 239 else 240 { 241 values[msFiles.indexOf(feature.getMsFile())] += feature 242 .getIntegratedIntensity().floatValue(); 243 } 236 244 nValues++; 237 245 if (currentCharge == 0) … … 245 253 246 254 247 private void printRow(PrintWriter writer, float[] values,255 private void printRow(PrintWriter writer, Float[] values, 248 256 Long currentCluster, String currentSequence, String currentAcc, 249 257 int currentCharge, float rtSum, float nValues, boolean conflict) … … 256 264 writer 257 265 .print("\t" + currentAcc + "\t" + currentCharge + "\t" + (rtSum / nValues)); 258 for ( float value : values)266 for (Float value : values) 259 267 { 260 268 writer.print("\t" + value);
Note: See TracChangeset
for help on using the changeset viewer.