Before asking this question read
though neither posed the same question or provide the answer to the present question.
In Modern Human Diversity - Skin Color published by The Smithsonian National Museum of Natural History the document in pertinent part states
As early humans moved into hot, open environments in search of food and water, one big challenge was keeping cool. The adaptation that was favored involved an increase in the number of sweat glands on the skin while at the same time reducing the amount of body hair. With less hair, perspiration could evaporate more easily and cool the body more efficiently. But this less-hairy skin was a problem because it was exposed to a very strong sun, especially in lands near the equator. Since strong sun exposure damages the body, the solution was to evolve skin that was permanently dark so as to protect against the sun’s more damaging rays.
...
The darker skin of peoples who lived closer to the equator was important in preventing folate deficiency. Measures of skin reflectance, a way to quantify skin color by measuring the amount of light it reflects, in people around the world support this idea. While UV rays can cause skin cancer, because skin cancer usually affects people after they have had children, it likely had little effect on the evolution of skin color because evolution favors changes that improve reproductive success.
There is also a third factor which affects skin color: coastal peoples who eat diets rich in seafood enjoy this alternate source of vitamin D. That means that some Arctic peoples, such as native peoples of Alaska and Canada, can afford to remain dark-skinned even in low UV areas. In the summer they get high levels of UV rays reflected from the surface of snow and ice, and their dark skin protects them from this reflected light.
Cases: Lighter skinned populations who migrated to tropical regions (for example, Mennonites in Belize, Boers in South Africa, Belgians in Congo (DRC)) and darker skinned populations which migrated to non-tropical regions (for example Africans in Britain, Africans in the northern U.S. States and Alaska, and Africans in Canada), where the diets of the populations take on the diets which in part led to the specific pigmentation, and the sun applies the same amount of light (UV; other spectrums) to the population as the population where darker or lighter skin adapted, or evolved.
Given the parameters provided, a lay person might conclude that they should be able to migrate to a specific tropic or non-tropic region of the world, take on the diet which led to the melanin production and skin pigmentation which the article states influences adaption or evolution, and over N fixed generations, or an unknown period of time, though eventually, their skin pigmentation will adapt or evolve to the population planners' desired pigmentation; that melanin production and skin pigmentation is not fixed, that evolution and adaptation as to skin pigmentation is continuously ongoing in the human population on Earth circa 2019 CE - and the claim is capable of being reproduced, observed and objectively measured using the scientific method.
Have any scientific studies been performed which substantiates or refutes by observable measurement the theory or claim that environment and diet have an effect on melanin production and skin pigmentation within the scope of any timescale ("One generation, two generations, ten generations, 10-20 generations")?