While making a logistic regression model, when I set multi_class='ovr' in iris dataset, my accuracy reduced to 0. 833 which without It was 1. I can't understand why is this happening. Can anybody help?

While making a logistic regression model, when I set multi_class=‘ovr’ in iris dataset, my accuracy reduced to 0. 833 which without It was 1. I can’t understand why is this happening. Can anybody help?

Hi @shreya_vajpayee
You need to assess if your problem is binary classification (2 classes of target variable) or multiclass classification (more than 2 classes).

When the parameter multi-class is not set explicitly, it automatically determines which type of problem it is and applies ovr for binary and multinomial for multi-class classification.

Also, ‘ovr’ is used if your problem is binary classification. Iris data is a multi class problem as there are 3 species of flowers.
You are giving a multi class data to the model and asking the model to perform binary classification. So you are getting your accuracy reduced.