public ReducedErrorPruning(DecisionTree tree, double[][] inputs, int[] outputs) { this.tree = tree; this.inputs = inputs; this.outputs = outputs; this.info = new Dictionary<DecisionNode, NodeInfo>(); this.actual = new int[outputs.Length]; foreach (var node in tree) info[node] = new NodeInfo(); for (int i = 0; i < inputs.Length; i++) trackDecisions(tree.Root, inputs[i], i); }