Researchers have figured out that about 30 percent of new cancer diagnoses and half of all cancer deaths in the US could be avoided.

That's a lot. So what's the secret? The most obvious way is to never smoke or to quit, but the researchers found three other lifestyle factors that matter a lot, too: cutting down on alcohol, keeping a healthy bodyweight, and exercising.

In the 2016 paper in JAMA Oncology, researchers from the Harvard T.H. Chan School of Public Health and Harvard Medical School used data from two big cohort studies — the Nurses’ Health Study and the Health Professionals Follow-Up Study — to assess how lifestyle factors were linked to a person's cancer risk. (The cohorts were predominantly white, and the researchers chose to analyze only whites since they didn't have enough participants of other races to represent the general population.)

To tease out cancer risk, they divided the participants into low- and high-risk groups based on four well-known cancer risk factors: cigarette smoking, alcohol consumption, body mass index (to measure overweight and obesity), and physical activity.

The low-risk group was made up of people who never smoked or smoked for only a few years and people who drank no or only small amounts of alcohol (one or fewer drinks per day for women and two or fewer for men). It also included people with a BMI between 18.5 and 27.5, and people who exercised vigorously for at least 75 minutes per week or moderately for 150 minutes.

The high-risk group was made up of everybody who did not meet these criteria.

As you can see, for every type of cancer they looked at, the high-risk group had a greater chance of a cancer diagnosis compared with the low-risk group:

This was especially true when it came to smoking- and drinking-related diseases like lung, esophagus, and oropharyngeal cancers.

People with high-risk behaviors generally had worse outcomes when it came to surviving cancer:

There are some important limitations of this study to keep in mind: ​Again, the participants in the cohorts the researchers looked at were white. And there are notable differences in the diagnosis and experience of different types of cancer among racial groups. The study population was also comprised of health professionals, who generally have a healthier lifestyle than the rest of the population (which may explain why — as shown in the tables above — the high-risk group in the study often had a lower risk of cancer compared to the general population).

Still, the research agrees with other similar epidemiological studies that have already been done. "​The big takeaway," said lead author and Harvard research fellow Mingyang Song, "is that a substantial number of cancer cases and deaths in the US can be prevented by modification of lifestyle factors." The study also provides "strong support for the importance of environmental factors in cancer risk," and a reminder that many types of cancer are indeed preventable.

Some cancers may be preventable, but others are just random

You may recall the controversial "bad luck" cancer research published in 2015 that focused on how random genetic mutations can drive many cases of cancer.

As the authors of that study, Bert Vogelstein and Cristian Tomasetti, told Vox in an email, "[These] unavoidable mutations occurring during normal stem cell divisions could be at least as important as [hereditary and environmental factors]."

The authors of the study also point out that patients with optimal lifestyles — who exercise regularly and don't smoke or drink — can face cancer diagnoses. And for these cases, investing in improving cancer detection methods and treatments is hugely important. "Prevention is optimal when it can be used, but in many cancers and cancer types," Vogelstein and Tomasetti wrote, "[early detection and treatment] will be the key to reducing morbidity and mortality."

In a commentary related to the JAMA Oncology study, Graham A. Colditz and Siobhan Sutcliffe, of Washington University School of Medicine St. Louis, disagree. They argue that a focus on preventing cancer is what's needed. This gets at the heart of a debate that's playing out in cancer medicine: Should the bulk of public money and effort go into funding cancer treatment or prevention?

The JAMA commentary authors argue that prevention is key: "This large excess of cancer is not inevitable but rather can be tackled by a broad range of interventions at multiple levels, including strategies at the clinician level, the individual level, the community level, and the society level through regulatory change," they wrote.

They say this could include everything from changing the way doctors are compensated for counseling patients on modifying their behaviors to encouraging healthier patterns of eating with subsidies on fruits and vegetables.

In truth, cancer is many, many different diseases. Some types will be preventable; others won't be. Public funding should probably go toward fighting both types.

The top reason people die early, in each country