Michigan teachers have it pretty good according to a recent study released by the personal finance website Wallethub.

In the data crunch released on Sept. 25, Michigan is ranked as the 12th best state for teachers in 2017.

The study compares the 50 states and the District of Columbia based on 21 key indicators of teacher-friendliness including teachers' income growth potential, pupil-teacher ratio and teacher safety.

Michigan received a total score of 57.82 just ahead of Rhode Island and just ahead of Utah.

Michigan was bolstered by high rankings in the opportunity and competition category, where it ranked 5th overall. Michigan did especially well in in the highest annual salary adjusted for cost of living metric where it was No. 1.

Also of interest was Michigan's rank in the lowest projected competition metric where it was No. 5. This examines things such as teachers per student in the year 2024. For this study, that's considered a good thing.

Michigan ranked significantly lower in the academic and work environment category where it was No. 31. This category includes things such as quality of school system, pupil-teacher ratio, presence of annual teacher evaluations, teacher turnover, teacher union strength and more.

New York, New Jersey, Illinois, Connecticut and Pennsylvania are the top 5 states for teachers, according to the study. Arizona, Hawaii, South Carolina, Mississippi and Florida are considered the bottom 5, according to Wallethub.