BOSTON (AP) — A ban on sugary sodas, potato chips and other standard vending machine fare from Massachusetts schools appears to be working.

That’s according to a study that looked at 74 middle schools and high schools in more than three dozen school districts over an 18-month period.

READ MORE: Gov. Charlie Baker To Make Announcement About COVID Testing And Schools

Before the new rules, just 13 percent of competitive foods would have met the standards at the middle school level.

One year after the rule, that number rose to 69 percent.

READ MORE: Moderna Plans To Have Combination COVID Booster, Flu Vaccine Ready By Fall 2023

At the high school level, just 28 percent of competitive beverages met the standards before the rules. Compliance jumped to 80 percent one year after the rules.

Northeastern associate professor Jessica Hoffman, the study’s lead author, said the findings are encouraging because Massachusetts’ standards were some of strictest in the country at the time.

MORE NEWS: Registration For Pan-Mass Challenge Opens Tuesday

Copyright 2015 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.