I’ve been measuring my weight for the last three years, with measurements every 3 or 4 days. Recently I purchased a scale that also calculates BMI automatically and realised I never recorded BMI in the past. Since this is a normal calculation I though I could create a Siri Shortcut to read historical data of the weight, take the date the measurement happened, then calculate the BMI and log it into the health app on the same date.
So far I have been unsuccessful as I am having trouble with the loops and recursion.