The heart can only take so much — and a new study suggests that the combination of strenuous exercise and high emotions may be too much for it to bear.

In the study, working out while angry or emotionally upset was linked to a more than threefold greater risk of having a heart attack within the hour.

The researchers also looked at exercise and emotional stress individually, to see if each factor, on its own, would affect the risk of heart attack. They found that each of these factors more than doubled a person's risk of having a heart attack within the hour, according to the study, published today (Oct. 10) in the journal Circulation. [Beyond Vegetables and Exercise: 5 Ways to Be Heart Healthy]

Although regular physical activity has many benefits, including heart disease prevention, the researchers said they "would recommend that a person who is angry or upset [and] who wants to exercise to blow off steam not go beyond their normal routine" and to not exercise at extreme levels, Dr. Andrew Smyth, a researcher at the HRB Clinical Research Facility in Ireland and the lead author of the study, said in a statement.

In the study, the researchers looked at data on 12,500 patients from 52 countries who'd had one heart attack. All of the patients were participants in the INTERHEART study, which looked at risk factors for heart attacks.

During the INTERHEART study, the participants answered questions about their activities in the hour leading up to their heart attack, including whether they had been engaged in strenuous physical activity or had been angry or emotionally upset. The researchers also asked the patients if they had engaged in those same activities or had been in those same emotional states during the same time of day on the day before their heart attack.

Both physical exertion and certain emotions can affect the body in ways that can raise a person's heart attack risk, the researchers wrote in the study.

"Both can raise blood pressure and heart rate, changing the flow of blood through blood vessels and reducing blood supply to the heart," Smyth said. If a person already has blood vessels that are narrowed by plaque, this could be particularly risky, he added.

The researchers noted that the study had several limitations. For example, the study participants were asked to recall their physical activity levels and emotional states during the time period leading up to their heart attacks, and their memories may not have been perfect.

Originally published on Live Science.