diff --git a/AVCDecisionTreeForest.m b/AVCDecisionTreeForest.m index bf0cf4c9..fd98330d 100644 --- a/AVCDecisionTreeForest.m +++ b/AVCDecisionTreeForest.m @@ -322,12 +322,14 @@ Mathematica is (C) Copyright 1988-2012 Wolfram Research, Inc. Clear[RandomAxes] RandomAxes[nDimensions_] := - Which[ - nDimensions > 10, RandomSample[Range[nDimensions], 5], - nDimensions > 5, RandomSample[Range[nDimensions], 3], - nDimensions > 2, RandomSample[Range[nDimensions], 2], - True, Range[nDimensions] - ]; + Sort[ + Which[ + nDimensions > 10, RandomSample[Range[nDimensions], 5], + nDimensions > 5, RandomSample[Range[nDimensions], 3], + nDimensions > 2, RandomSample[Range[nDimensions], 2], + True, Range[nDimensions] + ] + ]; Clear[BuildDecisionTree] Options[BuildDecisionTree] = {"RandomAxes" -> False,