Refactoring for Weka 3-7-11.