MCPcopy Index your code
hub / github.com/WinVector/Logistic / BLevelRow

Class BLevelRow

src/com/winvector/variables/BObserver.java:33–57  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

31 }
32
33 public final class BLevelRow {
34 public double totalForLevel = 0.0;
35 public final double[] totalByCorrectCategory;
36 public final double[] sumRunCorrectCategory;
37 public final double[] sumRunFixedCategory;
38 public final double[] sumPCorrectCategory;
39 public final double[] sumPFixedCategory;
40
41 public BLevelRow() {
42 totalByCorrectCategory = new double[noutcomes];
43 sumRunCorrectCategory = new double[noutcomes];
44 sumRunFixedCategory = new double[noutcomes];
45 sumPCorrectCategory = new double[noutcomes];
46 sumPFixedCategory = new double[noutcomes];
47 }
48
49 public void observe(final BLevelRow o) {
50 totalForLevel += o.totalForLevel;
51 sumLeft(totalByCorrectCategory,o.totalByCorrectCategory);
52 sumLeft(sumRunCorrectCategory,o.sumRunCorrectCategory);
53 sumLeft(sumRunFixedCategory,o.sumRunFixedCategory);
54 sumLeft(sumPCorrectCategory,o.sumPCorrectCategory);
55 sumLeft(sumPFixedCategory,o.sumPFixedCategory);
56 }
57 }
58
59 /*
60 * per-variable statistics

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected