Logistic regression implemented