predict function implemented
using new predict function in app