and I need a boolean as a return for the train(data) method