Added predictions and test-predict code