The benefits of logging my eating behavior and challenges exporting my data

I posted in my last entry about the various different metrics that I track with devices and apps and how I think about and use my data. One of my top tracking priorities is to note the names of the foods that I eat and the quantities I consume at each meal. I want to share some details about why and how I do this and some of the challenges I have encountered along the way. In a later blog, I’ll share more details about my latest iteration of an import approach that lets me process my MFP food log into a format I can import into JMP.

Why do I track what I eat?

I track my food as a means of accountability and history keeping. This practice provides immediate daily benefit as a means for calorie intake estimation and monitoring my food choices. When considering whether I can fit in a dessert in the evening, it helps to flip my phone sideways to the summary view (shown below) to see if I’m close to my calorie goal for the day. With a glance, I can review my detailed daily log to see if met other daily goals (e.g., having several kinds of vegetables).

Sideways summary view

In the longer term, keeping a food log allows me to look back and understand the patterns in my weight or body fat trends over time. If I don’t keep records of what and how much I ate, then I’m left to depend on my admittedly faulty memory to interpret the patterns I see. If my weight trends up or down, there could be so many possible reasons, from overtraining to overeating to too much sodium to getting into the habit of having a few glasses of wine on the weekend. In the absence of detailed records, my general impressions about my eating habits aren’t dependable enough to explain the patterns I see or help me determine the right intervention when my metrics go in the wrong direction. Earlier this year, my weight crept up beyond my normal maintenance zone due to eating more calories. To reverse that trend, I had to work on reducing daily calories to get my monthly total down. I’ve now moved my mean weight down back towards my preferred range. Sometimes I just need a refresher on where I need to be calorie-wise to keep my weight where I want it-generally, well under 2000 calories a day.

Weight and calories consumed 6 months

I’ve found that keeping detailed food records also helps me isolate and quantify the impact of trigger foods on my metrics. Trigger foods are items that I simply don’t seem to be able to eat in controlled amounts and therefore they cause me major calorie control problems. I suspect almost everyone has their own unique list of such foods. My list of trigger foods includes honey roasted peanuts, peanut M&Ms, semisweet chocolate chips, and (the worst possible form of food drug) chocolate covered espresso beans. By keeping records of my food choices, I can quantify the impact of known and potential trigger foods on my diet and visualize how cutting them out helps me stay on track.

Weight and Espresso beans

Early in the year, when my calories were trending upwards, it was partly due to a major chocolate covered espresso bean addiction. Between the dark/white/speckled expresso bean mix in building R on the SAS campus and also Trader Joes, they were just too easy to get! I just had to kick the habit. Yes, it’s uncomfortable to talk about eating habits that border on addictions, but most of us have them. That’s the beauty of using food logs to assess patterns-you can choose what you share with others about what you find, but you personally can learn from the data whether you choose to share it or not.

What details do I track about my eating?

Although it works well for some people, I have found it’s not quite enough for me to track just the names of the foods I eat, but rather, I need to get as exact as possible about amounts. As a 5’4.5” woman who has struggled with weight most of my life, it’s just too easy for me to get into the habit of eating more calories than my daily budget allows, even if my choices are what would be commonly considered “clean” or “healthy.”

There are plenty of people gaining weight on otherwise “healthy” foods simply because they eat more than they burn in a day. I believe food choices are important for gut microbiome health and diversity, of course, but my data also shows me that I can include some “unhealthy” junk foods and still maintain my weight…as long as I keep total calories and calorie balance in the right place.  Until I have an inexpensive real-time sensor to tell me more about what’s going on with my internal calorie balance on a daily basis, I will continue to monitor it with a combination of food logging, activity monitoring, and tracking my weight and body composition.

What’s my daily time investment for logging my food?

Logging my meals only takes me a few minutes a day. Right now you’re probably thinking, “Wait, what? Logging an entire day’s worth of food must take a lot longer than that.” And it used to, back in the days when I logged my food in notebooks. It consumed even more time to look up the macros for each food amount in a nutritional value food reference book and calculate the calories and macro percentages for each day. When I look back at how I managed food logging in the days before I had a smart phone with an electronic log and immediate access to an extensive food database, my current approach looks so efficient in comparison that logging feels like a no brainer. It literally only takes me only a minute or two to search for and log foods names and quantities for each meal.

People who have a negative impression about the time required for food logging will probably never get started or will give up early in the learning curve when faced with their first hard-to-quantify dinner out. Perhaps willingness to track long-term is somewhat personality-driven. Adopting a daily food logging practice seems to appeal most to very detail-oriented people. I have also noticed that those who have a personal investment in learning from their data because of past or present struggles with weight gain tend to stick with it. Perhaps they have had some initial success examining their own patterns and getting an idea of what works for them and what doesn’t, and have found that tracking helps them keep on track.

That’s certainly been the case for me. Looking back at my historical notebooks, I can see that I usually tracked when working towards a weight loss goal, but once I achieved it, I often stopped logging because of the time commitment required for my former, largely manual process. Unfortunately, my data shows that when I picked up my log book at a later date and began tracking again, I had always regained at least some of the weight I lost. Some people naturally eat to maintenance and stay weight stable for years without tracking, but clearly my data tells me that’s not my pattern. Understanding this pattern and committing to long-term tracking has become a critical piece of my weight maintenance strategy over the past 3.5 years, helping me avoid regaining the 50 pounds I lost after my last pregnancy. Although my weight does still fluctuate generally within a 5-10 lb range, this is fairly small in comparison to what I’ve experienced in the past.

How did I get started tracking my food?

The first time I logged my food was back in junior high when I learned from my mother that keeping track of what I ate could help me to lose weight. We thought it was the magic of counting carbs but hadn’t yet realized that carb-counting was just a form of restricting calories.  I tracked my food on and off over the years and have been tracking consistently in electronic form since the end of 2010.

Doesn’t tracking take the fun out of eating?

A lot of people think that the kind of detailed food tracking I do is a crazy form of obsessive compulsive behavior that takes the joy out of eating. Maybe it would feel like that to some people, but I don’t feel that keeping my data negatively impacts my enjoyment of food. I enjoy eating and I no longer beat myself up for my food choices or feel like my weight is a factor that is out of my control. But it is true that quantifying has helped me become more objective about the connection between my food patterns and my weight, which have both been very emotionally charged topics for me in the past (as they are for most people).

I have talked to people who say they want to lose weight yet don’t want to know what and how much they’re eating. I also see overweight people spending hours a week on cardio machines in the gym, not making any visible progress over long periods of time, and I wonder if they are also spending the relatively few minutes a day to log their eating and use their data to guide weight loss efforts.

I used to be that person on the treadmill, elliptical or bike, not really enjoying what I was doing, and justifying my overeating with exercise. It absolutely does not surprise me at all that recent weight loss research reveals that seeing exercise as an unenjoyable chore can lead to compensatory pleasure-seeking behavior in other areas, including eating. It’s trivially easy to negate any weight loss benefit to exercise with a minute or two of overeating. I always love Craig Ballantyne’s Diet vs. Exercise YouTube video series for illustrating that!

I’m certainly not judging people who struggle with overeating and weight as I have been there myself many times. I often stopped tracking during holiday periods of consistent overeating (hence the weight gain that resulted in between tracking periods). I understand now that I didn’t like seeing the truth that I was choosing to overeat. Refusing to collect the data and face the problem objectively was a way of letting myself off the hook. If I didn’t have the data, or didn’t look at it frequently, I could go on believing that I was doing everything right or mostly right, but it just wasn’t working for me. With actual data in front of me, I can start to be more objective about the situation.

What food tracking apps have I used?

I used BodyMedia’s food logging app daily for nearly four years before switching to the free MyFitnessPal (MFP) app. Although I did consider using BodyMedia’s MFP integration while I was using their activity monitor armband and app, I preferred the convenience of having my activity monitor and food log data together in a single app. Unfortunately, the limited BodyMedia food database meant I had to add many custom items and recipes to it. This personal investment was one of the factors that kept me from investigating other tools.

When I switched to using a FitBit Charge HR last March, I was forced to re-evaluate my food logging tool. I tested the FitBit food logging app and MyFitnessPal side-by-side for a few days. Ultimately, I chose MFP because of its extensive food database which can be accessed by a simple text or voice search. I have actually never needed to add a custom recipe to MFP. I’m certain that there some error associated with selection of certain combination items that don’t exactly match what I’m eating. But then again, not even food labels should be taken as gospel since they’re all based on averages anyway. To combat the error-prone nature of food logging in general, I tend to add 10% to the quantities I log.

Other features of MFP that I liked:

  • I was able to send my MFP calories consumed daily summary back to my FitBit account, putting calories burned and consumed data “in the same place” and letting me track my effective deficit for daily accountability.
  • Since I log my food in grams wherever possible, I thought the MFP app offered a better food quantity adjustment widget than the FitBit app did. I just couldn’t see myself using a scrollwheel to set serving sizes in grams like I would have to in FitBit’s app-the direct entry edit box used by MFP just made more sense.


  • I could select from a frequent foods list and add multiple items to a meal with radio buttons in MFP, and adjusting quantities in that mode was just one click away.


One downside to the MFP meal structure was that unlike BodyMedia which had six different slots for meals, MFP only has four. BodyMedia had the ability for me to assign foods to breakfast, morning snack, lunch, afternoon snack, dinner and late snack. The lower resolution on snack timing in MFP makes it more difficult to distinguish eating timing patterns that might be causing me issues. Unless I want to laboriously enter food notes for every meal to tag items to a specific time frame, I can’t easily distinguish which foods were eaten at which snack times. This is unfortunate, but was obviously not a deal breaker for me.

How do I get my detailed food log data out of these tools?

The biggest frustration that I have with MFP is the exact same one I had with BodyMedia-that is, just how painful it is to get my detailed food log data in an analysis ready format.  Both tools only offer detailed food log export as PDF, which is really just a presentation format that is not directly useful for analysis work. BodyMedia was slightly worse in that it only allowed me to export my data tables as PDF in four week chunks, forcing me to save each individual file to text and write a complicated JSL script that used regular expression parsing to grab date and meal names and propagate them throughout all rows of the table, then concatenate the various files. Early on, I also parsed and concatenated years’ worth of BodyMedia activity data stored in multi-worksheet Excel workbooks, each spanning a 4 week period. I did this programmatically in both cases, and uploaded a Fitness and Food add-in to the JMP file exchange for this import, but clearly coming up with this kind of approach is not an option for everyone. I even stopped using it myself when I began to use Zenobase [LINK], a third party tool, for data export and aggregation.

I find it interesting that FitBit recently imposed a similar monthly limitation on export time frame, citing server load issues as customers’ data histories grow, and this has generated many user complaints on their forum. I’ve followed the updates to several of those threads. I have been talking to other companies about their lack of data export tools in recent months so I know that FitBit is not alone in facing export challenges. Although they recently made their export free instead of including it in a premium membership, I prefer using Zenobase to get at the higher resolution hourly data that Fitbit doesn’t offer to customers directly. Zenobase retrieves this information via the FitBit API and stores it for me. You can try it out in free mode, but the more devices you own, the more it makes sense to pay $5 a month for greater storage capacity.

Unfortunately, food log access doesn’t seem to be available via API for either of the tools I have used, and third party solutions for MFP export are spotty at best, mostly covering retrieval of day-level data and well-summarized in this post on the Quantified Self blog. A Chrome extension I used to use called MyFitnessPal Data Downloader did a lot of the detailed food log PDF to text conversion and pre-processing work for me, but it was discontinued for unknown reasons in the current version of Chrome. MyFitnessPal has been slow to offer data export in a CSV or Excel format despite many user requests, though I heard from them at their QS15 booth that they are planning to offer an improved export feature at some point.

Recently, I decided it was time to bite the bullet and redo my import script for MFP food log data import. I had already checked out the MFP export FAQ and saw no further progress on exporting an analysis ready CSV file. Just to be sure, I tweeted at MFP Support to verify that I hadn’t missed anything. They clearly didn’t read the link in my tweet to my detailed query and feedback about their current PDF export options and sent me a link to the PDF export FAQ.

In my next blog, I’ll share more details about how I extracted the text information I needed from MFP’s PDF reports, parsed and cleaned it up so I could make graphs like the one above. I have to note that in comparison, exporting my weight data from my Withings account was a snap. Export my entire history as CSV? Sure, here you go-file immediately downloaded! I love it.  Thank you, Withings, for making one of the many data sets I maintain accessible in the standard format everyone else should be using!


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s