adding code to read in training data (need to add test data)