Health insurer Anthem Inc. will effectively leave Affordable Care Act markets in Wisconsin and Indiana in 2018, it announced.