Analyzing My Personal Fitness Data
- bethp91
- Jun 2, 2022
- 4 min read
Updated: Jun 2, 2022
Growing up I was surrounded by family and friends who took living healthy lifestyles very seriously. As a result, I have loved being active and staying healthy and fit most of my life. The last three years my job has added extreme amounts of stress and the work load has been huge. One of the things I let go was my health and fitness and I have been working on making some positive changes in that area.
I wanted to see if I was hitting the recommended 10,000 steps a day, how many calories I was burning to help me with my diet plan, and how long I was spending exercising.
Let's dive into the process.
The Opportunity
The idea behind this project was to utilize the data collected to accomplish my bigger health goals. I have a very specific goal of losing 40 lbs. Knowing my calorie baseline will be helpful in reaching this goal.
Data Collection
Thankfully we live in a day and age where tracking daily calories burnt is not impossible. In fact, with all the smart devices most of us have it is rather easy. I typically wear my Apple Watch daily, including when I sleep. If for some reason I do not have my watch on I do have my iPhone 13 with me and it tracks my steps.
While these devices are accurate there is always room for error. For this projects sake we will assume that most of the data collected is accurate.
Even though these devices track our fitness data the don't make it extremely easy to access or export this data. Due to this issue I used a third party app called, HealthExport.
Here is what the data looks like.

As you can see the data has the date, active energy burned(calories), stand hours, basal energy burned, distance, exercise time, flights climbed, heart rate, resting heart rate, stand time, step count, and walking heart rate column.
Once I had this data exported and loaded as a CSV. I was ready to analyze it.
Analyzing the Data
For this project I used Python to do some automated, quick analysis, and to learn how to use Python better.
I used Google Colab as my IDE. which is great because it is a cloud based notebook. You can check out my notebook by following this link!
Or you can just check out my code below!
First I used Pandas to import the CSV for analysis.
I then used the term df.describe() to get some basic descriptive analytics for the data table.
It was actually really informative and fascinating!
Calories
Insight: I learned that I burn and average of 545 calories/day. This was more than I thought as I have not been consistent with my exercise as I ought to be. It also shows me I need to be more conscious of my calorie intake each day.
Action: Be consistent with my workouts and eat much healthier. If I can do these two things I should be able to make progress towards my goal of losing 40 lbs.
Exercise
Insight: I learned that my average exercise time was 21 min/session. This is 9 minutes shy of 30 minutes/session. I have a personal goal of 30 minutes daily of some form of exercise so this was informative.
Action: If I just work out and extra 9 minutes/session I will be able to meet my goal of 30 minutes/session and that extra could lead to more weight loss and my big goal.
Steps
Insight: According to my data I take an average of 7,751 steps/day. This is 2,249 steps short of the recommended 10,000 steps per day. Having a job that requires lots of paperwork and testing I was not surprised by this.
Action: If I can get up and move more between testing or data collecting periods and be more active once I am home I can reach the recommended 10,00 steps/day and this can also move the needle in my favor of weight lost.
Distance
Insight: Analyzing my data showed that on average I walk or run 3 mile/day. This isn't much as I know cardio is very helpful in losing weight.
Action: Get moving! I have set a goal of running 1 mile/day to help me get in the habit of moving each day. I hope to increase this as I become fitter and healthier.
Using Boolean Masks I was able to see my longest distance walked or ran in a day. My longest distance was 7.6 miles and that was very insightful for me. It showed that I can accomplish it if I just put my mind to it.
Conclusion
This data set has been very interesting to analyze and I feel like I have been able to find some great takeaways and insights to help me reach my goals.
Eat healthier to maximize the calories burned.
Exercise 9 more minutes per session to reach the 30 minutes.
Get up and move more to reach the 10,000 step goal.
Start my day off with a mile to get my body and mind in the mindset of moving.


Comments