This document shows how to split a given dataset into a training dataset and a test dataset, while preserving class distribution, using Weka. Note that the screenshots shown here may not be exactly the same as those you will see on your computer. Open the initial dataset. Click the Choosebutton below Filter. Then, click filters – supervised – instance. Then, choose Resample.