There's a lot of these scenarios that are well documented, anything from the loosely defined and often poorly understood epigenetics processes, but also the signaling regulation of cell growth and death, resulting changes with hormesis, acclimatization, availability/scarcity of nutrients, hormones, pharmaceuticals, viruses, and even mental state.
(1) is typically the largest factor of all that listed, with experiments showing repeatedly that 'genetic markers' specifying risk for heart disease, cancer, etc all vastly improve with a reduction of excess body fat and elimination of recreational drug usage such as excessive alcohol and cigarettes.
And as for (4), definitely a trump card is not taking a dump in your drinking water supply without reasonable recycling treatment. Many people tend to associate the medical industry as responsible for the supposed improved living conditions of modern developed countries. However, if you look at the repeated succession stages of colonialization throughout the past several hundred years, it's obvious that when people in underdeveloped countries stop shitting in their food and water, illness and resulting death plummet until a few generations later when economically enforced diets and 'sensible medical care' are in full effect leading to a rebound of misery.
Farmers have generally had pretty terrible (imbalanced) diets until the last century or so because one's diet was heavily dependent on the seasons and local climate.
So they invented and clinically tested Intermittent Fasting? Trendsetters! ;-D
I don't disagree with you, but here's my point - they weren't eating Cheesy Poofs and Mac and Cheese, they were eating... greens, legumes, root vegetables, etc. Whatever was local and seasonal or that they could preserve using salting or canning. In this regard, even if there was scarcity, what they were eating was likely better for them than what much of our population calls food today.
So, what's my point on all this? My own anecdata tells me:
1) Eat real food, like those long-lived ancestors. 2) Move / exercise. Most of them were physically active farmers, while I sit here coding away at a desk. 3) Hope you don't have any obvious genetic markers for cancer, heart disease, etc. 4) Be thankful for modern sanitation and immunization! Get your shots, including flu shots!