Tech

Resolving data sync inconsistencies in calorie counts and energy expenditure that arise with Apple Health integrations

Fresh Fitness Food

Apple Health and Fresh Fitness Food: How many calories did the team at Calcey burn to find a solution for data integration?

In December 2020, Fresh Fitness Food, one of London’s leading providers of bespoke nutrition, took the next step in on-the-go accessibility through the launch of its mobile app. Fresh Fitness Food (FFF) provides precision nutrition tailored to each individual’s needs and dietary restrictions. With the new mobile app, however, FFF has the potential to be so much more. 

The app can track fitness goals, daily activity, and calorie expenditure. It can then suggest and provide guided workouts and meal plans to help you achieve your goal. Real-time data can be entered on the go and accounted for in the design of your next meal. FFF employs a Michelin-star-trained menu consultant to create this bespoke meal plan and will deliver it right to your door. 

Calcey, who developed a new web portal for FFF, was the team behind the design of the mobile app. The app was meant to be easily connectable with other activity-tracking devices and programs such as Fitbits and Apple Health. However, soon after the launch, the team was made aware of a discrepancy. 

Where’s the fire?

The number of calories burnt each day was provided to the user through the FFF app. To do this, the app would integrate data from Apple Health or any other fitness monitoring system the user already had. When comparing the numbers provided by the app against those provided by Apple Health, it was found that they varied by 50-200 calories each day. The team at Calcey was puzzled over this inconsistency and began to search for an explanation. Seek and ye shall find – the team soon discovered the reason behind this.

Apple Health used a system of time intervals to produce the final number of calories burnt at the end of the day. It was a two-part calculation, using Active Energy – the energy expenditure while walking, exercising, etc- and Resting Energy – the energy spent for metabolic processes such as food digestion. Some time intervals however, would straddle two days. E.g. – 11.30 pm to 12.30 am. This was the cause of the discrepancy between the data recorded by the FFF app vs Apple Health. 

Douse the flames

Once this was brought to light, the next step for Calcey was to find a way to extract the correct number of calories belonging to each day. They did this by proportionately allocating calories based on time. Eg – If the time period was 11.30 pm – 12.30 am and the total calories burnt during this time was 100, 50 calories would be allocated to the first day and 50 to the second. Similarly, if it was 11.45 – 12.45 with the same number of calories, 25 calories would be allocated to the first day while 75 would be included in the count for the second day. 

The team wrote and re-programmed the FFF app to include this method of calculation and the change has been implemented for future downloads. Any user who was affected by this discrepancy in the month since the app’s launch was afforded the opportunity to have their calorie number corrected and updated. The team at Calcey does not anticipate any further stumbling blocks with the FFF app; however, should any arise, the team will spend as many calories as required to ensure the best possible service is provided to a client!

Fresh Fitness Food
Fresh Fitness Food with Calcey
IT companies in Sri Lanka