So-called 'yo-yo dieting' — where people lose weight and gain it back again – doubles the risk of a heart attack, stroke or death in people who've already got significant heart disease.

That's the conclusion of an international study published recently in the New England Journal of Medicine.

Researchers reviewed weight data gathered over several years from 9,509 people with significant heart disease who had taken part in a trial of a cholesterol-lowering statin drug. The study was sponsored by the drug maker Pfizer.

"Our findings suggest that we need to be concerned about weight fluctuation in this group that is already at high risk due to coronary disease," says lead researcher Dr. Sripal Bangalore a cardiologist at NYU Langone Medical Center in New York City.

Over a period averaging 4.7 years, people who had the greatest fluctuations in weight — about 8.6 pounds — had double the risk of a heart attack, stroke or death, when compared with those who experienced weight fluctuations of less than 2 pounds.

The odds of developing new-onset diabetes were also increased for people with the greatest variability in weight versus those with the lowest variability.

Dr. Martha Gulati says the findings should encourage physicians to help patients set more realistic goals for weight loss. She's chief of cardiology at the University of Arizona and spokesperson for the American College of Cardiology. She was not involved with the study.

"People will say to me, 'I'm going to lose 40 pounds,' and so if they lose 10 pounds they get frustrated and decide 'game over I'm done' — and go back to their old dietary habits," Gulati says. This mindset typically results in gaining back those lost pounds, she says.

The bottom line health message from the study is this: If you succeed in losing weight, then you should work just as hard to keep it off, says Linda Van Horn, a registered dietitian and professor of preventive medicine at Northwestern University's Feinberg School of Medicine and a spokesperson for the American Heart Association.

Unfortunately, keeping the pounds off can be more difficult as people age, Van Horn says.

"The older we get the fewer calories we need," she says. "If a person who is 60 is eating the same number of calories they ate when they were 20, they will be considerably heavier," she says, even if there has been no change in physical activity.

That's because metabolism decreases over time, starting in the mid-20s.

So, as people age, it's even more important to keep an eye on the scale and cut back when weight increases, Van Horn says. "It's a lot easier to gain than it is to lose."

Why would this sort of "weight cycling" increase the risk of a heart attack or stroke? Researchers say they don't know for sure, but they have some ideas.

Gulati suggests it may be that levels of the stress hormone, cortisol increase. That can affect blood pressure, diabetes and cholesterol levels — all of which are all well known risk factors for heart disease and stroke.

Copyright 2017 NPR. To see more, visit http://www.npr.org/.