better predictions
diff --git a/.gitignore b/.gitignore
index 98a7cc1..63e896e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -98,5 +98,7 @@
 *.log
 *.pot
 
+sample-app
+
 # Sphinx documentation
 docs/_build/
\ No newline at end of file
diff --git a/README.md b/README.md
index 595fbfe..a97dd6c 100755
--- a/README.md
+++ b/README.md
@@ -5,37 +5,63 @@
 Modeled after [scikit-learn's RandomForestClassifier](http://scikit-learn.org/dev/modules/generated/sklearn.ensemble.RandomForestClassifier.html).
 
 ```javascript
-var RandomForestClassifier = require('random-forest-classifier');
+var fs = require('fs'),
+    RandomForestClassifier = require('../index.js').RandomForestClassifier;
 
-RandomForestClassifier
+var data = [
+  {
+    "length":5.1,
+    "width":3.5,
+    "petal_length":1.4,
+    "petal_width":0.2,
+    "species":"setosa"
+  },
+  {
+    "length":6.5,
+    "width":3,
+    "petal_length":5.2,
+    "petal_width":2,
+    "species":"virginica"
+  },
+  {
+    "length":6.6,
+    "width":3,
+    "petal_length":4.4,
+    "petal_width":1.4,
+    "species":"versicolor"
+  }...
+];
+
+var testdata = [{
+    "length":6.3,
+    "width":2.5,
+    "petal_length":5,
+    "petal_width":1.9,
+    //"species":"virginica"
+  },
+  {
+    "length":4.7,
+    "width":3.2,
+    "petal_length":1.3,
+    "petal_width":0.2,
+    //"species":"setosa"
+  }...
+];
+
+var rf = new RandomForestClassifier({
+    n_estimators: 10
+});
+
+rf.fit(data, null, "species", function(err, trees){
+  //console.log(JSON.stringify(trees, null, 4));
+  var pred = rf.predict(testdata, trees);
+
+  console.log(pred);
+
+  // pred = ["virginica", "setosa"]
+});
 ```
 
-
-## Goals
-
-**MOST OF THESE DON'T WORK THEY ARE JUST A GOAL I SET**
-
 ### Parameters
 
 **`n_estimators`:** *integer, optional (default=10)* The number of trees in the forest.
-
-**`criterion`:** *string, optional (default=“entropy”)* The function to measure the quality of a split. Supported criteria are “gini” for the Gini impurity and “entropy” for the information gain. Note: this parameter is tree-specific.
-
-**`max_features`:** *int, float, string or None, optional (default=”auto”)* The number of features to consider when looking for the best split:
-- If int, then consider max_features features at each split.
-- If float, then max_features is a percentage and int(max_features * n_features) features are considered at each split.
-- If “auto”, then max_features=sqrt(n_features).
-- If “sqrt”, then max_features=sqrt(n_features).
-- If “log2”, then max_features=log2(n_features).
-- If None, then max_features=n_features.
-Note: the search for a split does not stop until at least one valid partition of the node samples is found, even if it requires to effectively inspect more than max_features features. Note: this parameter is tree-specific.
-
-**`max_depth`:** *integer or None, optional (default=None)* The maximum depth of the tree. If None, then nodes are expanded until all leaves are pure or until all leaves contain less than min_samples_split samples. Ignored if max_samples_leaf is not None. Note: this parameter is tree-specific.
-
-**`min_samples_split`:** *integer, optional (default=2)* The minimum number of samples required to split an internal node. Note: this parameter is tree-specific.
-
-**`min_samples_leaf`:** *integer, optional (default=1)* The minimum number of samples in newly created leaves. A split is discarded if after the split, one of the leaves would contain less then min_samples_leaf samples. Note: this parameter is tree-specific.
-
-**`max_leaf_nodes`:** *int or None, optional (default=None)* Grow trees with max_leaf_nodes in best-first fashion. Best nodes are defined as relative reduction in impurity. If None then unlimited number of leaf nodes. If not None then max_depth will be ignored. Note: this parameter is tree-specific.
-
-**`verbose`:** *int, optional (default=0)* Controls the verbosity of the tree building process.
\ No newline at end of file
diff --git a/forest/index.js b/forest/index.js
index 502cf6b..7b4f9df 100755
--- a/forest/index.js
+++ b/forest/index.js
@@ -61,11 +61,12 @@
 */
 
 var async = require('async'),
+    utils = require('../utilities'),
     DecisionTreeClassifier = require('../tree');
 
 var RandomForestClassifier = function(params) {
     this.n_estimators = params.n_estimators || 10;
-    this.criterion = params.criterion || "gini";
+    this.criterion = params.criterion || "entropy";
     this.max_features = params.max_features || "auto";
     this.min_samples_split = params.min_samples_split || 2;
     this.min_samples_leaf = params.min_samples_leaf || 1;
@@ -74,8 +75,9 @@
 
 var _parallel_build_tree = function(data, features, y) {
     return function (n, next) {
-        var tree = new DecisionTreeClassifier({});
-        var CLF = tree.fit(data, features, y);
+        var CLF = new DecisionTreeClassifier({});
+        var tree = CLF.fit(data, features, y);
+        CLF.model = tree;
         next(null, CLF);
     };
 };
@@ -86,12 +88,25 @@
         // this is done async because it can be independent
         async.times(this.n_estimators, _parallel_build_tree(data, features, y), function(err, trees) {
             if (err) { console.log(err); }
-            this.trees = trees;
 
             cb(err, trees);
         });
     },
-    predict: function() {
+    predict: function(data, trees) {
+        this.trees = trees;
+        var probabilities = new Array(data.length);
+        for (var i=0; i < data.length ;i++) {
+            var dec = [];
+            for (var j=0; j < this.n_estimators; j++){
+                dec.push(trees[i].predict(data[i]));
+            }
+            if (utils.GetType(dec[0]) == "string"){
+                probabilities[i] = utils.GetDominate(dec);
+            } else {
+                probabilities[i] = utils.Average(dec);
+            }
+        }
+        return probabilities;
     }
 };
 
diff --git a/package.json b/package.json
index bdbbc7b..50bb68e 100755
--- a/package.json
+++ b/package.json
@@ -24,5 +24,9 @@
   "dependencies": {
     "async": "^0.9.0",
     "underscore": "^1.6.0"
+  },
+  "devDependencies": {
+    "ejs": "^1.0.0",
+    "express": "^4.4.4"
   }
 }
diff --git a/tests/index.js b/tests/index.js
index 836bb55..72acfbf 100755
--- a/tests/index.js
+++ b/tests/index.js
@@ -2,57 +2,70 @@
     file = __dirname + '/iris.json',
     RandomForestClassifier = require('../index.js').RandomForestClassifier;
 
+// 0 == setosa
+// 1 == versicolor
+// 2 == virginica
+
 var testdata = [{
     "length":6.9,
     "width":3.1,
-    "petal.length":5.1,
-    "petal.width":2.3,
-    "species":"virginica"
+    "petal_length":5.1,
+    "petal_width":2.3,
+    //"species":"virginica"
   },
   {
     "length":5.1,
     "width":3.8,
-    "petal.length":1.5,
-    "petal.width":0.3,
-    "species":"setosa"
+    "petal_length":1.5,
+    "petal_width":0.3,
+    //"species":"setosa"
   },
   {
     "length":5,
     "width":2.3,
-    "petal.length":3.3,
-    "petal.width":1,
-    "species":"versicolor"
+    "petal_length":3.3,
+    "petal_width":1,
+    //"species":"versicolor"
   },
   {
     "length":6.2,
     "width":3.4,
-    "petal.length":5.4,
-    "petal.width":2.3,
-    "species":"virginica"
+    "petal_length":5.4,
+    "petal_width":2.3,
+    //"species":"virginica"
   },
   {
     "length":4.9,
     "width":3,
-    "petal.length":1.4,
-    "petal.width":0.2,
-    "species":"setosa"
+    "petal_length":1.4,
+    "petal_width":0.2,
+    //"species":"setosa"
+  },
+  {
+    "length":4.7,
+    "width":3.2,
+    "petal_length":1.3,
+    "petal_width":0.2,
+    //"species":"setosa"
   }
 ];
 
 
 fs.readFile(file, 'utf8', function (err, data) {
-  if (err) {
-    console.log('Error reading iris json file: ' + err);
-  }
+    if (err) {
+        console.log('Error reading iris json file: ' + err);
+    }
 
-  data = JSON.parse(data);
+    data = JSON.parse(data);
 
-  var rf = new RandomForestClassifier({});
+    var rf = new RandomForestClassifier({
+      n_estimators: 20
+    });
 
-  // find a way to make this sync
-  rf.fit(data, null, "species", function(err, trees){
-    console.log(JSON.stringify(trees, null, 4));
-
-
+    rf.fit(data, null, "species", function(err, trees){
+        //console.log(trees);
+        //console.log(JSON.stringify(trees, null, 4));
+        var pred = rf.predict(testdata, trees);
+        console.log(pred);
   });
 });
\ No newline at end of file
diff --git a/tests/iris.json b/tests/iris.json
index dbcc0aa..03e4ee6 100755
--- a/tests/iris.json
+++ b/tests/iris.json
@@ -2,1016 +2,1016 @@
   {
     "length":5.1,
     "width":3.5,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.7,
     "width":3.2,
-    "petal.length":1.3,
-    "petal.width":0.2,
+    "petal_length":1.3,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.6,
     "width":3.1,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.6,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.4,
     "width":3.9,
-    "petal.length":1.7,
-    "petal.width":0.4,
+    "petal_length":1.7,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":4.6,
     "width":3.4,
-    "petal.length":1.4,
-    "petal.width":0.3,
+    "petal_length":1.4,
+    "petal_width":0.3,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.4,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.4,
     "width":2.9,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.9,
     "width":3.1,
-    "petal.length":1.5,
-    "petal.width":0.1,
+    "petal_length":1.5,
+    "petal_width":0.1,
     "species":"setosa"
   },
   {
     "length":5.4,
     "width":3.7,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.8,
     "width":3.4,
-    "petal.length":1.6,
-    "petal.width":0.2,
+    "petal_length":1.6,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.8,
     "width":3,
-    "petal.length":1.4,
-    "petal.width":0.1,
+    "petal_length":1.4,
+    "petal_width":0.1,
     "species":"setosa"
   },
   {
     "length":4.3,
     "width":3,
-    "petal.length":1.1,
-    "petal.width":0.1,
+    "petal_length":1.1,
+    "petal_width":0.1,
     "species":"setosa"
   },
   {
     "length":5.8,
     "width":4,
-    "petal.length":1.2,
-    "petal.width":0.2,
+    "petal_length":1.2,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.7,
     "width":4.4,
-    "petal.length":1.5,
-    "petal.width":0.4,
+    "petal_length":1.5,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":5.4,
     "width":3.9,
-    "petal.length":1.3,
-    "petal.width":0.4,
+    "petal_length":1.3,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":5.1,
     "width":3.5,
-    "petal.length":1.4,
-    "petal.width":0.3,
+    "petal_length":1.4,
+    "petal_width":0.3,
     "species":"setosa"
   },
   {
     "length":5.7,
     "width":3.8,
-    "petal.length":1.7,
-    "petal.width":0.3,
+    "petal_length":1.7,
+    "petal_width":0.3,
     "species":"setosa"
   },
   {
     "length":5.4,
     "width":3.4,
-    "petal.length":1.7,
-    "petal.width":0.2,
+    "petal_length":1.7,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.1,
     "width":3.7,
-    "petal.length":1.5,
-    "petal.width":0.4,
+    "petal_length":1.5,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":4.6,
     "width":3.6,
-    "petal.length":1,
-    "petal.width":0.2,
+    "petal_length":1,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.1,
     "width":3.3,
-    "petal.length":1.7,
-    "petal.width":0.5,
+    "petal_length":1.7,
+    "petal_width":0.5,
     "species":"setosa"
   },
   {
     "length":4.8,
     "width":3.4,
-    "petal.length":1.9,
-    "petal.width":0.2,
+    "petal_length":1.9,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3,
-    "petal.length":1.6,
-    "petal.width":0.2,
+    "petal_length":1.6,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.4,
-    "petal.length":1.6,
-    "petal.width":0.4,
+    "petal_length":1.6,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":5.2,
     "width":3.5,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.2,
     "width":3.4,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.7,
     "width":3.2,
-    "petal.length":1.6,
-    "petal.width":0.2,
+    "petal_length":1.6,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.8,
     "width":3.1,
-    "petal.length":1.6,
-    "petal.width":0.2,
+    "petal_length":1.6,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.4,
     "width":3.4,
-    "petal.length":1.5,
-    "petal.width":0.4,
+    "petal_length":1.5,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":5.2,
     "width":4.1,
-    "petal.length":1.5,
-    "petal.width":0.1,
+    "petal_length":1.5,
+    "petal_width":0.1,
     "species":"setosa"
   },
   {
     "length":5.5,
     "width":4.2,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.9,
     "width":3.1,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.2,
-    "petal.length":1.2,
-    "petal.width":0.2,
+    "petal_length":1.2,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.5,
     "width":3.5,
-    "petal.length":1.3,
-    "petal.width":0.2,
+    "petal_length":1.3,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.9,
     "width":3.6,
-    "petal.length":1.4,
-    "petal.width":0.1,
+    "petal_length":1.4,
+    "petal_width":0.1,
     "species":"setosa"
   },
   {
     "length":4.4,
     "width":3,
-    "petal.length":1.3,
-    "petal.width":0.2,
+    "petal_length":1.3,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.1,
     "width":3.4,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.5,
-    "petal.length":1.3,
-    "petal.width":0.3,
+    "petal_length":1.3,
+    "petal_width":0.3,
     "species":"setosa"
   },
   {
     "length":4.5,
     "width":2.3,
-    "petal.length":1.3,
-    "petal.width":0.3,
+    "petal_length":1.3,
+    "petal_width":0.3,
     "species":"setosa"
   },
   {
     "length":4.4,
     "width":3.2,
-    "petal.length":1.3,
-    "petal.width":0.2,
+    "petal_length":1.3,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.5,
-    "petal.length":1.6,
-    "petal.width":0.6,
+    "petal_length":1.6,
+    "petal_width":0.6,
     "species":"setosa"
   },
   {
     "length":5.1,
     "width":3.8,
-    "petal.length":1.9,
-    "petal.width":0.4,
+    "petal_length":1.9,
+    "petal_width":0.4,
     "species":"setosa"
   },
   {
     "length":4.8,
     "width":3,
-    "petal.length":1.4,
-    "petal.width":0.3,
+    "petal_length":1.4,
+    "petal_width":0.3,
     "species":"setosa"
   },
   {
     "length":5.1,
     "width":3.8,
-    "petal.length":1.6,
-    "petal.width":0.2,
+    "petal_length":1.6,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":4.6,
     "width":3.2,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5.3,
     "width":3.7,
-    "petal.length":1.5,
-    "petal.width":0.2,
+    "petal_length":1.5,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":5,
     "width":3.3,
-    "petal.length":1.4,
-    "petal.width":0.2,
+    "petal_length":1.4,
+    "petal_width":0.2,
     "species":"setosa"
   },
   {
     "length":7,
     "width":3.2,
-    "petal.length":4.7,
-    "petal.width":1.4,
+    "petal_length":4.7,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":6.4,
     "width":3.2,
-    "petal.length":4.5,
-    "petal.width":1.5,
+    "petal_length":4.5,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":6.9,
     "width":3.1,
-    "petal.length":4.9,
-    "petal.width":1.5,
+    "petal_length":4.9,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":5.5,
     "width":2.3,
-    "petal.length":4,
-    "petal.width":1.3,
+    "petal_length":4,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.5,
     "width":2.8,
-    "petal.length":4.6,
-    "petal.width":1.5,
+    "petal_length":4.6,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":5.7,
     "width":2.8,
-    "petal.length":4.5,
-    "petal.width":1.3,
+    "petal_length":4.5,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.3,
     "width":3.3,
-    "petal.length":4.7,
-    "petal.width":1.6,
+    "petal_length":4.7,
+    "petal_width":1.6,
     "species":"versicolor"
   },
   {
     "length":4.9,
     "width":2.4,
-    "petal.length":3.3,
-    "petal.width":1,
+    "petal_length":3.3,
+    "petal_width":1,
     "species":"versicolor"
   },
   {
     "length":6.6,
     "width":2.9,
-    "petal.length":4.6,
-    "petal.width":1.3,
+    "petal_length":4.6,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":5.2,
     "width":2.7,
-    "petal.length":3.9,
-    "petal.width":1.4,
+    "petal_length":3.9,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":5,
     "width":2,
-    "petal.length":3.5,
-    "petal.width":1,
+    "petal_length":3.5,
+    "petal_width":1,
     "species":"versicolor"
   },
   {
     "length":5.9,
     "width":3,
-    "petal.length":4.2,
-    "petal.width":1.5,
+    "petal_length":4.2,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":6,
     "width":2.2,
-    "petal.length":4,
-    "petal.width":1,
+    "petal_length":4,
+    "petal_width":1,
     "species":"versicolor"
   },
   {
     "length":6.1,
     "width":2.9,
-    "petal.length":4.7,
-    "petal.width":1.4,
+    "petal_length":4.7,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":5.6,
     "width":2.9,
-    "petal.length":3.6,
-    "petal.width":1.3,
+    "petal_length":3.6,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.7,
     "width":3.1,
-    "petal.length":4.4,
-    "petal.width":1.4,
+    "petal_length":4.4,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":5.6,
     "width":3,
-    "petal.length":4.5,
-    "petal.width":1.5,
+    "petal_length":4.5,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":5.8,
     "width":2.7,
-    "petal.length":4.1,
-    "petal.width":1,
+    "petal_length":4.1,
+    "petal_width":1,
     "species":"versicolor"
   },
   {
     "length":6.2,
     "width":2.2,
-    "petal.length":4.5,
-    "petal.width":1.5,
+    "petal_length":4.5,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":5.6,
     "width":2.5,
-    "petal.length":3.9,
-    "petal.width":1.1,
+    "petal_length":3.9,
+    "petal_width":1.1,
     "species":"versicolor"
   },
   {
     "length":5.9,
     "width":3.2,
-    "petal.length":4.8,
-    "petal.width":1.8,
+    "petal_length":4.8,
+    "petal_width":1.8,
     "species":"versicolor"
   },
   {
     "length":6.1,
     "width":2.8,
-    "petal.length":4,
-    "petal.width":1.3,
+    "petal_length":4,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.3,
     "width":2.5,
-    "petal.length":4.9,
-    "petal.width":1.5,
+    "petal_length":4.9,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":6.1,
     "width":2.8,
-    "petal.length":4.7,
-    "petal.width":1.2,
+    "petal_length":4.7,
+    "petal_width":1.2,
     "species":"versicolor"
   },
   {
     "length":6.4,
     "width":2.9,
-    "petal.length":4.3,
-    "petal.width":1.3,
+    "petal_length":4.3,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.6,
     "width":3,
-    "petal.length":4.4,
-    "petal.width":1.4,
+    "petal_length":4.4,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":6.8,
     "width":2.8,
-    "petal.length":4.8,
-    "petal.width":1.4,
+    "petal_length":4.8,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":6.7,
     "width":3,
-    "petal.length":5,
-    "petal.width":1.7,
+    "petal_length":5,
+    "petal_width":1.7,
     "species":"versicolor"
   },
   {
     "length":6,
     "width":2.9,
-    "petal.length":4.5,
-    "petal.width":1.5,
+    "petal_length":4.5,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":5.7,
     "width":2.6,
-    "petal.length":3.5,
-    "petal.width":1,
+    "petal_length":3.5,
+    "petal_width":1,
     "species":"versicolor"
   },
   {
     "length":5.5,
     "width":2.4,
-    "petal.length":3.8,
-    "petal.width":1.1,
+    "petal_length":3.8,
+    "petal_width":1.1,
     "species":"versicolor"
   },
   {
     "length":5.5,
     "width":2.4,
-    "petal.length":3.7,
-    "petal.width":1,
+    "petal_length":3.7,
+    "petal_width":1,
     "species":"versicolor"
   },
   {
     "length":5.8,
     "width":2.7,
-    "petal.length":3.9,
-    "petal.width":1.2,
+    "petal_length":3.9,
+    "petal_width":1.2,
     "species":"versicolor"
   },
   {
     "length":6,
     "width":2.7,
-    "petal.length":5.1,
-    "petal.width":1.6,
+    "petal_length":5.1,
+    "petal_width":1.6,
     "species":"versicolor"
   },
   {
     "length":5.4,
     "width":3,
-    "petal.length":4.5,
-    "petal.width":1.5,
+    "petal_length":4.5,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":6,
     "width":3.4,
-    "petal.length":4.5,
-    "petal.width":1.6,
+    "petal_length":4.5,
+    "petal_width":1.6,
     "species":"versicolor"
   },
   {
     "length":6.7,
     "width":3.1,
-    "petal.length":4.7,
-    "petal.width":1.5,
+    "petal_length":4.7,
+    "petal_width":1.5,
     "species":"versicolor"
   },
   {
     "length":6.3,
     "width":2.3,
-    "petal.length":4.4,
-    "petal.width":1.3,
+    "petal_length":4.4,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":5.6,
     "width":3,
-    "petal.length":4.1,
-    "petal.width":1.3,
+    "petal_length":4.1,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":5.5,
     "width":2.5,
-    "petal.length":4,
-    "petal.width":1.3,
+    "petal_length":4,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":5.5,
     "width":2.6,
-    "petal.length":4.4,
-    "petal.width":1.2,
+    "petal_length":4.4,
+    "petal_width":1.2,
     "species":"versicolor"
   },
   {
     "length":6.1,
     "width":3,
-    "petal.length":4.6,
-    "petal.width":1.4,
+    "petal_length":4.6,
+    "petal_width":1.4,
     "species":"versicolor"
   },
   {
     "length":5.8,
     "width":2.6,
-    "petal.length":4,
-    "petal.width":1.2,
+    "petal_length":4,
+    "petal_width":1.2,
     "species":"versicolor"
   },
   {
     "length":5.6,
     "width":2.7,
-    "petal.length":4.2,
-    "petal.width":1.3,
+    "petal_length":4.2,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":5.7,
     "width":3,
-    "petal.length":4.2,
-    "petal.width":1.2,
+    "petal_length":4.2,
+    "petal_width":1.2,
     "species":"versicolor"
   },
   {
     "length":5.7,
     "width":2.9,
-    "petal.length":4.2,
-    "petal.width":1.3,
+    "petal_length":4.2,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.2,
     "width":2.9,
-    "petal.length":4.3,
-    "petal.width":1.3,
+    "petal_length":4.3,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":5.1,
     "width":2.5,
-    "petal.length":3,
-    "petal.width":1.1,
+    "petal_length":3,
+    "petal_width":1.1,
     "species":"versicolor"
   },
   {
     "length":5.7,
     "width":2.8,
-    "petal.length":4.1,
-    "petal.width":1.3,
+    "petal_length":4.1,
+    "petal_width":1.3,
     "species":"versicolor"
   },
   {
     "length":6.3,
     "width":3.3,
-    "petal.length":6,
-    "petal.width":2.5,
+    "petal_length":6,
+    "petal_width":2.5,
     "species":"virginica"
   },
   {
     "length":5.8,
     "width":2.7,
-    "petal.length":5.1,
-    "petal.width":1.9,
+    "petal_length":5.1,
+    "petal_width":1.9,
     "species":"virginica"
   },
   {
     "length":7.1,
     "width":3,
-    "petal.length":5.9,
-    "petal.width":2.1,
+    "petal_length":5.9,
+    "petal_width":2.1,
     "species":"virginica"
   },
   {
     "length":6.3,
     "width":2.9,
-    "petal.length":5.6,
-    "petal.width":1.8,
+    "petal_length":5.6,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.5,
     "width":3,
-    "petal.length":5.8,
-    "petal.width":2.2,
+    "petal_length":5.8,
+    "petal_width":2.2,
     "species":"virginica"
   },
   {
     "length":7.6,
     "width":3,
-    "petal.length":6.6,
-    "petal.width":2.1,
+    "petal_length":6.6,
+    "petal_width":2.1,
     "species":"virginica"
   },
   {
     "length":4.9,
     "width":2.5,
-    "petal.length":4.5,
-    "petal.width":1.7,
+    "petal_length":4.5,
+    "petal_width":1.7,
     "species":"virginica"
   },
   {
     "length":7.3,
     "width":2.9,
-    "petal.length":6.3,
-    "petal.width":1.8,
+    "petal_length":6.3,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.7,
     "width":2.5,
-    "petal.length":5.8,
-    "petal.width":1.8,
+    "petal_length":5.8,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":7.2,
     "width":3.6,
-    "petal.length":6.1,
-    "petal.width":2.5,
+    "petal_length":6.1,
+    "petal_width":2.5,
     "species":"virginica"
   },
   {
     "length":6.5,
     "width":3.2,
-    "petal.length":5.1,
-    "petal.width":2,
+    "petal_length":5.1,
+    "petal_width":2,
     "species":"virginica"
   },
   {
     "length":6.4,
     "width":2.7,
-    "petal.length":5.3,
-    "petal.width":1.9,
+    "petal_length":5.3,
+    "petal_width":1.9,
     "species":"virginica"
   },
   {
     "length":6.8,
     "width":3,
-    "petal.length":5.5,
-    "petal.width":2.1,
+    "petal_length":5.5,
+    "petal_width":2.1,
     "species":"virginica"
   },
   {
     "length":5.7,
     "width":2.5,
-    "petal.length":5,
-    "petal.width":2,
+    "petal_length":5,
+    "petal_width":2,
     "species":"virginica"
   },
   {
     "length":5.8,
     "width":2.8,
-    "petal.length":5.1,
-    "petal.width":2.4,
+    "petal_length":5.1,
+    "petal_width":2.4,
     "species":"virginica"
   },
   {
     "length":6.4,
     "width":3.2,
-    "petal.length":5.3,
-    "petal.width":2.3,
+    "petal_length":5.3,
+    "petal_width":2.3,
     "species":"virginica"
   },
   {
     "length":6.5,
     "width":3,
-    "petal.length":5.5,
-    "petal.width":1.8,
+    "petal_length":5.5,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":7.7,
     "width":3.8,
-    "petal.length":6.7,
-    "petal.width":2.2,
+    "petal_length":6.7,
+    "petal_width":2.2,
     "species":"virginica"
   },
   {
     "length":7.7,
     "width":2.6,
-    "petal.length":6.9,
-    "petal.width":2.3,
+    "petal_length":6.9,
+    "petal_width":2.3,
     "species":"virginica"
   },
   {
     "length":6,
     "width":2.2,
-    "petal.length":5,
-    "petal.width":1.5,
+    "petal_length":5,
+    "petal_width":1.5,
     "species":"virginica"
   },
   {
     "length":6.9,
     "width":3.2,
-    "petal.length":5.7,
-    "petal.width":2.3,
+    "petal_length":5.7,
+    "petal_width":2.3,
     "species":"virginica"
   },
   {
     "length":5.6,
     "width":2.8,
-    "petal.length":4.9,
-    "petal.width":2,
+    "petal_length":4.9,
+    "petal_width":2,
     "species":"virginica"
   },
   {
     "length":7.7,
     "width":2.8,
-    "petal.length":6.7,
-    "petal.width":2,
+    "petal_length":6.7,
+    "petal_width":2,
     "species":"virginica"
   },
   {
     "length":6.3,
     "width":2.7,
-    "petal.length":4.9,
-    "petal.width":1.8,
+    "petal_length":4.9,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.7,
     "width":3.3,
-    "petal.length":5.7,
-    "petal.width":2.1,
+    "petal_length":5.7,
+    "petal_width":2.1,
     "species":"virginica"
   },
   {
     "length":7.2,
     "width":3.2,
-    "petal.length":6,
-    "petal.width":1.8,
+    "petal_length":6,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.2,
     "width":2.8,
-    "petal.length":4.8,
-    "petal.width":1.8,
+    "petal_length":4.8,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.1,
     "width":3,
-    "petal.length":4.9,
-    "petal.width":1.8,
+    "petal_length":4.9,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.4,
     "width":2.8,
-    "petal.length":5.6,
-    "petal.width":2.1,
+    "petal_length":5.6,
+    "petal_width":2.1,
     "species":"virginica"
   },
   {
     "length":7.2,
     "width":3,
-    "petal.length":5.8,
-    "petal.width":1.6,
+    "petal_length":5.8,
+    "petal_width":1.6,
     "species":"virginica"
   },
   {
     "length":7.4,
     "width":2.8,
-    "petal.length":6.1,
-    "petal.width":1.9,
+    "petal_length":6.1,
+    "petal_width":1.9,
     "species":"virginica"
   },
   {
     "length":7.9,
     "width":3.8,
-    "petal.length":6.4,
-    "petal.width":2,
+    "petal_length":6.4,
+    "petal_width":2,
     "species":"virginica"
   },
   {
     "length":6.4,
     "width":2.8,
-    "petal.length":5.6,
-    "petal.width":2.2,
+    "petal_length":5.6,
+    "petal_width":2.2,
     "species":"virginica"
   },
   {
     "length":6.3,
     "width":2.8,
-    "petal.length":5.1,
-    "petal.width":1.5,
+    "petal_length":5.1,
+    "petal_width":1.5,
     "species":"virginica"
   },
   {
     "length":6.1,
     "width":2.6,
-    "petal.length":5.6,
-    "petal.width":1.4,
+    "petal_length":5.6,
+    "petal_width":1.4,
     "species":"virginica"
   },
   {
     "length":7.7,
     "width":3,
-    "petal.length":6.1,
-    "petal.width":2.3,
+    "petal_length":6.1,
+    "petal_width":2.3,
     "species":"virginica"
   },
   {
     "length":6.3,
     "width":3.4,
-    "petal.length":5.6,
-    "petal.width":2.4,
+    "petal_length":5.6,
+    "petal_width":2.4,
     "species":"virginica"
   },
   {
     "length":6.4,
     "width":3.1,
-    "petal.length":5.5,
-    "petal.width":1.8,
+    "petal_length":5.5,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6,
     "width":3,
-    "petal.length":4.8,
-    "petal.width":1.8,
+    "petal_length":4.8,
+    "petal_width":1.8,
     "species":"virginica"
   },
   {
     "length":6.9,
     "width":3.1,
-    "petal.length":5.4,
-    "petal.width":2.1,
+    "petal_length":5.4,
+    "petal_width":2.1,
     "species":"virginica"
   },
   {
     "length":6.7,
     "width":3.1,
-    "petal.length":5.6,
-    "petal.width":2.4,
+    "petal_length":5.6,
+    "petal_width":2.4,
     "species":"virginica"
   },
   {
     "length":5.8,
     "width":2.7,
-    "petal.length":5.1,
-    "petal.width":1.9,
+    "petal_length":5.1,
+    "petal_width":1.9,
     "species":"virginica"
   },
   {
     "length":6.8,
     "width":3.2,
-    "petal.length":5.9,
-    "petal.width":2.3,
+    "petal_length":5.9,
+    "petal_width":2.3,
     "species":"virginica"
   },
   {
     "length":6.7,
     "width":3.3,
-    "petal.length":5.7,
-    "petal.width":2.5,
+    "petal_length":5.7,
+    "petal_width":2.5,
     "species":"virginica"
   },
   {
     "length":6.7,
     "width":3,
-    "petal.length":5.2,
-    "petal.width":2.3,
+    "petal_length":5.2,
+    "petal_width":2.3,
     "species":"virginica"
   },
   {
     "length":6.3,
     "width":2.5,
-    "petal.length":5,
-    "petal.width":1.9,
+    "petal_length":5,
+    "petal_width":1.9,
     "species":"virginica"
   },
   {
     "length":6.5,
     "width":3,
-    "petal.length":5.2,
-    "petal.width":2,
+    "petal_length":5.2,
+    "petal_width":2,
     "species":"virginica"
   },
   {
     "length":5.9,
     "width":3,
-    "petal.length":5.1,
-    "petal.width":1.8,
+    "petal_length":5.1,
+    "petal_width":1.8,
     "species":"virginica"
   }
 ]
\ No newline at end of file
diff --git a/tree/index.js b/tree/index.js
index f3370d4..bf5afc9 100755
--- a/tree/index.js
+++ b/tree/index.js
@@ -57,70 +57,34 @@
 
 DecisionTreeClassifier.prototype = {
     fit: function(data, features, y) {
-        var unique_y_values = _.unique(_.pluck(data, y));
-
-        // last leaf
-        if (unique_y_values.length == 1){
-            return {
-                type: "result",
-                val: unique_y_values[0],
-                name: unique_y_values[0],
-                alias: unique_y_values[0] + utils.RID()
-            };
-        }
-
-        if (features === true){
-            // end of branch
-            // returning the most dominate feature
-            var dominate_y = utils.GetDominate(unique_y_values);
-            return {
-                type:"result",
-                val: dominate_y,
-                name: dominate_y,
-                alias: dominate_y + utils.RID()
-            };
-        }
-
-        if (!features || features.length == 0){
-            // get all the features that are not y
-            features = _.reject(_.keys(data), function(f){ return f == y; });
-        }
-
-        var best_feature = _.max(features, function(f){return utils.Gain(data, f, y); });
-
-        var feature_remains = _.without(features, best_feature);
-
-        var possibilities = _.unique(_.pluck(data, best_feature));
-
-        var tree = {
-            name: best_feature,
-            alias: best_feature + utils.RID(),
-            type: "feature"
-        };
-
-        // create the branch of the tree
-        tree.vals = _.map(possibilities, function(v){
-            var data_modified = data.filter(function(x) { return x[best_feature] == v; });
-
-            var branch = {
-                name: v,
-                alias: v + utils.RID(),
-                type: "feature_value"
-            };
-
-            // recursive create children
-            var child = new DecisionTreeClassifier({});
-            if (feature_remains.length == 0){
-                feature_remains = true;
-            }
-            branch.child = child.fit(data_modified, feature_remains, y);
-
-            return branch;
-        });
-
-        return tree;
+      return utils.C45(data, features, y);
     },
-    predict: function(X, value) {
+    predict: function(sample) {
+        var root = this.model;
+
+        if (typeof root === 'undefined') {
+            return 'null';
+        }
+
+        while (root.type !== "result") {
+            var attr = root.name;
+            if (root.type === 'feature_real') {
+                var sample_value = parseFloat(sample[attr]);
+                if (sample_value <= root.cut){
+                    child_node = root.children[1];
+                } else {
+                    child_node = root.children[0];
+                }
+            } else {
+                var sample_value = sample[attr];
+                var child_node = _.detect(root.children, function(x) {
+                    return x.name == sample_value;
+                });
+            }
+            root = child_node.child;
+        }
+
+        return root.val;
     }
 };
 
diff --git a/utilities/index.js b/utilities/index.js
index 8948fc3..ab61731 100755
--- a/utilities/index.js
+++ b/utilities/index.js
@@ -1,27 +1,56 @@
 var _ = require("underscore");
 
 var Gain = function(data, feature, y){
-    var attribute_values = _.unique(_.pluck(data, feature)),
+    var attribute_values = _.pluck(data, feature),
         entropy = Entropy(_.pluck(data, y)),
-        size = _.size(data);
+        size = data.length,
+        feature_type = GetType(data[0][feature]);
 
-    var entropies = attribute_values.map(function(n){
-        var subset = data.filter(function(x){return x[feature] === n});
-        return ((subset.length/size) * Entropy(_.pluck(subset, y)));
-    });
+    if (feature_type == "float" || feature_type == "int"){
+        var entropies = attribute_values.map(function(n){
+            var cutf = parseFloat(n),
+                _gain = entropy - ConditionalEntropy(data, feature, y, cutf);
+            return {
+                feature: feature,
+                gain: _gain,
+                cut: cutf
+            };
+        });
+        return _.max(entropies, function(e){return e.gain});
+    } else {
+        var entropies = attribute_values.map(function(n){
+            var subset = data.filter(function(x){return x[feature] === n});
+            return ((subset.length/size) * Entropy(_.pluck(subset, y)));
+        });
 
-    var total_entropies =  entropies.reduce(function(a, b){ return a+b; }, 0);
-    return entropy - total_entropies;
+        var total_entropies =  entropies.reduce(function(a, b){ return a+b; }, 0);
+        return {
+            feature: feature,
+            gain: entropy - total_entropies,
+            cut: 0
+        };
+    }
+};
+
+var MaxGain = function(data, features, y){
+  var gains = [];
+  for(var i=0; i < features.length; i++) {
+    gains.push(Gain(data, features[i], y));
+  }
+  return _.max(gains,function(e){
+    return e.gain;
+  });
 };
 
 var GetDominate = function(vals){
-    var v = _.sortBy(vals, function(a){
-        return _.filter(vals, function(b) {
-            return b === a;
-        }).length;
-    }).reverse()[0];
-    return v;
-}
+    return  _.sortBy(vals, function(a){
+            return Count(a, vals);
+        }).reverse()[0];
+};
+
+var Count = function (a, vals){
+    return _.filter(vals, function(b) { return b === a}).length;
+};
 
 var Entropy = function(vals){
     var unique = _.unique(vals),
@@ -31,6 +60,13 @@
     return logs.reduce(function(a, b){ return a+b; }, 0);
 };
 
+var ConditionalEntropy = function(_s, feature, y, cut){
+    var s_1 = _s.filter(function(x){return x[feature] <= cut}),
+        s_2 = _s.filter(function(x){return x[feature] > cut}),
+        size = _s.length;
+    return s_1.length/size*Entropy(_.pluck(s_1, y)) + s_2.length/size*Entropy(_.pluck(s_1, y));
+};
+
 var Log2 = function(n){
     return Math.log(n)/Math.log(2);
 };
@@ -41,12 +77,189 @@
 };
 
 var RID = function(){
-    return "_r" + Math.round(Math.random()*1000000).toString();
+  return "_r" + Math.round(Math.random()*1000000).toString();
+};
+
+var GetType = function(input) {
+    var m = (/[\d]+(\.[\d]+)?/).exec(input);
+    if (m) {
+       // Check if there is a decimal place
+        if (m[1]) {
+            return 'float';
+        } else {
+            return 'int';
+        }
+    }
+    return 'string';
+};
+
+var Average = function(v){
+    var sum = v.reduce(function(a, b) { return a + b });
+    var avg = sum / v.length;
+    return avg;
 }
 
-module.exports.Gain = Gain;
+
+var C45 = function(data, features, y){
+    var tree = {};
+    var y_values = _.pluck(data, y);
+
+    // last leaf
+    if (y_values.length == 1) {
+        return {
+            type:"result",
+            val: y_values[0],
+            name: y_values[0],
+            alias: y_values[0] + RID()
+        };
+    }
+
+    if (features === true || y_values.length == 0){
+        // end of branch
+        // returning the most dominate feature
+        var dominate_y = GetDominate(y_values);
+        return {
+            type:"result",
+            val: dominate_y,
+            name: dominate_y,
+            alias: dominate_y + RID()
+        };
+    }
+
+    if (!features || features.length == 0){
+        // get all the features that are not y
+        features = _.reject(_.keys(data[0]), function(f){ return f == y; });
+    }
+
+    var best_feature_data = MaxGain(data, features, y),
+        best_feature = best_feature_data.feature;
+    var feature_remains = _.without(features, best_feature);
+    var best_feature_type = GetType(data[0][best_feature]);
+
+    // check if its an int/float
+    if (best_feature_type == "float" || best_feature_type == "int"){
+        tree = {
+            name: best_feature,
+            alias: best_feature + RID(),
+            cut: best_feature_data.cut,
+            type: "feature_real",
+            children: []
+        };
+
+        if (feature_remains.length == 0){
+            feature_remains = true;
+        }
+
+        var rightCutData = data.filter(function(x){ return x[best_feature] > best_feature_data.cut});
+        var child_node_r = {
+            name: tree.cut.toString(),
+            alias: '>' + tree.cut.toString() + RID(),
+            type: "feature_value"
+        };
+        child_node_r.child = C45(rightCutData, feature_remains, y);
+        tree.children.push(child_node_r);
+
+        var leftCutData = data.filter(function(x){return x[best_feature] <= best_feature_data.cut});
+        var child_node_l = {
+            name: tree.cut.toString(),
+            alias: '<=' + tree.cut.toString() + RID(),
+            type: "feature_value"
+        };
+        child_node_l.child = C45(leftCutData, feature_remains, y);
+        tree.children.push(child_node_l);
+    } else {
+        var possibilities = possibilities = _.unique(_.pluck(data, best_feature));
+        tree = {
+            name: best_feature,
+            alias: best_feature + RID(),
+            type: "feature",
+            children: []
+        };
+
+        tree.children = _.map(possibilities, function(v){
+            var data_modified = data.filter(function(x) { return x[best_feature] == v; });
+
+            var branch = {
+                name: v,
+                alias: v + RID(),
+                type: "feature_value"
+            };
+
+            if (feature_remains.length == 0){
+                feature_remains = true;
+            }
+            branch.child = C45(data_modified, feature_remains, y);
+
+            return branch;
+        });
+    }
+
+    return tree;
+};
+
+var ID3 = function(data, features, y){
+    var y_values = _.unique(_.pluck(data, y));
+
+    // last leaf
+    if (y_values.length == 1){
+        return {
+            type: "result",
+            val: y_values[0],
+            name: y_values[0],
+            alias: y_values[0] + RID()
+        };
+    }
+
+    if (features === true || y_values.length == 0){
+        // end of branch
+        // returning the most dominate feature
+        var dominate_y = GetDominate(_.pluck(data, y));
+        return {
+            type:"result",
+            val: dominate_y,
+            name: dominate_y,
+            alias: dominate_y + RID()
+        };
+    }
+
+    if (!features || features.length == 0){
+        // get all the features that are not y
+        features = _.reject(_.keys(data[0]), function(f){ return f == y; });
+    }
+
+    var best_feature = _.max(features, function(f){return Gain(data, f, y).gain; });
+    var feature_remains = _.without(features, best_feature);
+    var possibilities = _.unique(_.pluck(data, best_feature));
+    var tree = {
+        name: best_feature,
+        alias: best_feature + RID(),
+        type: "feature"
+    };
+
+    // create the branch of the tree
+    tree.children = _.map(possibilities, function(v){
+        var data_modified = data.filter(function(x) { return x[best_feature] == v; });
+
+        var branch = {
+            name: v,
+            alias: v + RID(),
+            type: "feature_value"
+        };
+
+        if (feature_remains.length == 0){
+            feature_remains = true;
+        }
+        branch.child = ID3(data_modified, feature_remains, y);
+
+        return branch;
+    });
+
+    return tree;
+}
+
+
+module.exports.ID3 = ID3;
+module.exports.C45 = C45;
+module.exports.GetType = GetType;
 module.exports.GetDominate = GetDominate;
-module.exports.Entropy = Entropy;
-module.exports.Log2 = Log2;
-module.exports.Probability = Probability;
-module.exports.RID = RID;
\ No newline at end of file
+module.exports.Average = Average;
\ No newline at end of file