The stew of bacteria that befouls some Minnesota lakes every summer and fall, poisoning dogs and closing beaches, also produces a unique pigment that can be seen from space.

Scientists believe they can now better forecast toxic outbreaks on lakes using satellites to detect the shade of green that cyanobacteria creates in water. A recent study from the Environmental Protection Agency paired satellite images with historical field data on more than 2,000 lakes across the country. It showed how the technology can be used to spot the lakes that are most at risk and prioritize where federal and state water managers need to take action, increase monitoring or close beaches.

"What's so exciting about this is that we can now distinguish cyanobacteria from more general algae or things like chlorophyl a," said Amalia Handler, EPA biologist and lead author. "There are so many lakes in a given state or area, so we need to know where is there greater or lesser risk."

The study found that by measuring the size and mass of a visible cyanobacteria outbreak in a lake, the EPA can start to predict how likely a dangerous toxic event will be.

Cyanobacteria outbreaks — also called blue-green algae outbreaks — have become so widespread that viewing them from space may offer state and federal agencies the best chance at tracking and monitoring them.

They have been increasing in nearly every part of the country over the last 20 years. The pests, which need sunlight and warm water full of nitrogen and phosphorus, now bloom and take over waters ranging from New York to California, and from Lake Okeechobee at the headwaters of the Florida Everglades to Lake Erie and other parts of the Great Lakes. They produce a toxin called microcystin.

The outbreaks cause lake water to smell like a stagnant swamp, and turn the water bright green. Dogs die within a few hours of ingesting it. Minnesotans have been hospitalized after swimming in infested lakes.

They happen naturally in rare cases in Minnesota when the conditions are right — typically when slow-moving and shallow nutrient-rich water reaches 75 degrees. But all the polluted runoff from croplands, feedlots and cities into lakes and rivers, along with warmer weather, have made outbreaks frequent and regular, disrupting the same lakes and ponds every year. Since 2012, they've been striking in even deep and historically colder waters such as Lake Superior, which scientists long believed were immune.

At first glance, the EPA study seems to suggest that Minnesota is the epicenter of cyanobacteria outbreaks in the U.S. A map shows that most of the lakes that the study found to be at the highest risk were in Minnesota, or just across the North Dakota and South Dakota borders.

But that is probably because Minnesota not only has the most lakes visible by satellite, but also the most field data tracking toxic outbreaks, said Aabir Banerji, an EPA ecologist in Duluth.

Historically, toxic outbreaks have been hard to predict because the bacteria seemed to change behaviors depending on the unique characteristics of every lake, he said.

"From lake to lake, we would get different answers for how to model an outbreak, which is why it has been so hard for a scientists to give good advice for when it might happen, other than to say if it's summer keep an eye out," Banerji said.

The study's findings solve some of those questions by showing what is happening on a larger scale. The study found that, over time, the likelihood of a toxic outbreak largely depends on the amount of cyanobacteria in the water.

There is still a great deal of uncertainty over why the bacteria thrives in some lakes and not others. The satellite images show several cases of pairs of neighboring lakes, all with similar dimensions, with one in the thick of an outbreak and the other healthy.

"There are all these local factors at play, which will be really interesting to delve into," Handler said.

The study shows a snapshot in time, using five years of satellite images and field data from between 2007 to 2012. Handler said she hopes it will lay the foundation for tracking more recent outbreaks, and to better compare just how much more vulnerable lakes are becoming over time.