Subscribe Bookmark


Jun 23, 2011

Digging into My Diet and Fitness Data With JMP

This is a longer (and yes, you guessed it, a more personally detailed!) version of a blog I wrote that will appear on the JMP blog in the near future..

If you’re a regular reader of the JMP blog, then you already know that those of us who work for JMP have taken a page from the Hair Club for Men.  I don’t mean in the use of their products, but rather in the use of our own products.  From our outside the office hobbies to internal activities, the people who work at JMP are also clients!  I had thought about using that classic line from Hair Club for men commercials while preparing my e-poster titled “Analysis of Personal Diet and Fitness Data With JMP®” for the upcoming JMP Discovery Summit 2014  conference in Cary.  Coincidentally, the very next week I saw this Linked In post on this very topic, talking about how “eating your own dog food” by using your own product is the best thing people on a product development team can do. 

I see daily examples of how using JMP on our own data helps JMP team members gain a deeper appreciation of the delights and frustrations of our users.  Working through data sets that we know well helps us find and report problems earlier and provide better feedback on features under development. On the JMP blog, you’ll find posts about optimizing baking and cooking efforts, importing iTunes data into JMP, tracking metrics from sporting events like the Olympics, milestones in baseball careers, and teaching our kids (with my favorite food, chocolate).  Our team members also use JMP for examining internal data on leads, sales, source file activity, and software defects.

In my previous position as JMP Genomics product manager, I spent most of my time working with internal and external customers and life sciences developers to guide new features for analysis of large SNP and expression data sets. The sheer size of genomics data sets can sometimes make it awkward to open and analyze them in memory on the desktop until they have been imported and pre-processed by SAS “behind the scenes,” like JMP Genomics does.  While I ventured into JMP’s other menus occasionally in my past role, I am certainly learning much more about its core functionality in my new position as senior manager of JMP’s development operations group.  Having interesting internal and personal data that I am passionate about exploring has been very key to my learning process.  I’m sure you can relate, whatever your own data and interests!

Over my next few JMP blogs, I will be sharing some of what I have learned while preparing my Discovery poster along with a few reflections on what I have learned during the first year of what I like to call “the PhD of me.”  While I have pursued other scientific interests in my education and career, collecting data on my own exercise and eating information has been a hobby of mine since high school.  Interestingly, the topics I pursued during my formal education turn out to be very relevant to my side interest.  My undergraduate studies at Mount Holyoke focused on the intersection between science and culture, with courses in interdisciplinary fields like biochemistry, molecular biology, and medical anthropology.  After graduation, I worked in human genetics and microbial genomics on my way to a PhD in bioinformatics.  However, my academic interests were not what led me to start recording information about my workouts and eating habits.

Instead, my interest in self-tracking has come from a long struggle with my own weight.  My tendency to overeat under stress began to catch up with me late in grade school and by 7th grade, I was overweight and self-conscious about it. My early attempts to tackle this issue included a low carb eating plan and a bodyweight exercise routine I did at home.  I took a strength training class over the summer after 7th grade and was hooked on lifting weights and getting stronger.  I tracked my workouts on printed cards all summer.  Once I started lifting weights at the YMCA, I began to keep a notebook to track my progress.  I’ve been lifting weights for so long now that getting back into in the weight room always feels like coming home-now more than ever, since I have acquired enough home gym equipment over the years to do the majority of my workouts at home!

By ninth grade, my efforts had paid off-I lost weight and reshaped my body.  I continued lifting weights at the YMCA throughout high school and earned varsity letters in basketball (I wasn’t very good) and track & field (I set a school record in discus which still stands).  It was heartbreaking when I lost a notebook containing several years of workout data in March of 1993.  Coincidentally, I had just met the man I would eventually marry, so I quickly got over the loss of that precious data!  My tracking habits over the next 5 years were considerably less organized as I dealt with the stress of the college decision process, the heavy course workload that followed, and a long-distance relationship.  I was active on the track team during my first year of college, but gave that up in my sophomore year to focus on my studies full time. 

Not surprisingly, I gained weight in college.  My activity levels dropped off when I left organized sports, but I never stopped eating like an athlete.  Although I walked all over campus and made sporadic attempts to exercise, overeating definitely got the best of me and by the time I headed to graduate school in mid-1998, I was at least 30 pounds overweight.  I successfully lost weight again in graduate school and maintained that loss until 2002, but changing my academic program followed by my first pregnancy in 2004 led me to regain all the weight that I had lost in middle school, plus a lot more.  My weight continued to swing up and down over the next four years until I decided I had had enough in mid-2008.  Although it took me a few years to do it, I had reached a healthier weight range by the time I entered my second pregnancy in early 2011.  I quickly lost the weight I gained during those 9 months and have been in weight maintenance mode since spring 2012. 

Wouldn’t it have been better just to share a graph instead of writing the paragraph above?  As all you early adopters know, in JMP 12, I can do exactly that!

7231_Weight Graph Grad School to Present 9-9-14.png

Over the years, I used a variety of heart rate monitors, pedometers, pulse and blood pressure monitors, though having to take and collate manual notes on those measures has been a hurdle in getting more of my data into analysis-ready format.  I have been thrilled with the evolution of activity monitors and smart phone apps capable of collecting data passively without the need for extensive note-taking!  The rise of activity monitors has fueled a whole movement called the Quantified Self that includes people like me who track one or more daily activities, ranging from diet and fitness information to internet use, sleep, stress levels, or other measures.   (I know my dad was greatly relieved when he found out that I wasn’t unique in my fascination with this kind of daily data collection!)

It may sound a bit weird or obsessive to people who don’t track information about themselves, but many QS fans find daily data collection incredibly useful in identifying and optimizing their dietary habits, daily routines, and other aspects of daily routines.  QS data can even be useful in health related pursuits.  Some have used it to successfully pinpoint mysterious food or environmental allergy triggers.  This past spring, my dad sent me a link to Gary Wolf’s 2010 Ted talk, and his description of the QS movement sounded immediately familiar to me.  I knew I had seen the clip before, but when?  One interesting thought-did I see it before purchasing my own activity monitor in late 2010?  Was it in fact what had motivated me to buy it?  I honestly can’t remember, but I definitely identify with the QS movement now than ever after nearly four years spent using a BodyMedia® FIT® armband activity tracker and its associated food logging software.

Like many users of such devices, I depend on the daily dashboards, weekly and monthly reports provided by the monitor’s web and app-based software to see short term trends.  I never seriously considered getting my data out of BodyMedia®’s software and into JMP until I had accumulated years’ worth of food logging and activity data.  Unfortunately, the longest time frame I could specify when exporting my activity data or food log information was 28 days.  After importing of my activity data from multi-worksheet Excel files interactively once with just two years’ worth of exported data files, I concluded that I would need to automate this process through scripting.  With my limited scripting experience, I knew this was not going to be a quick project, so I set it aside with the intent to return to the task later.

As time went on, I began to think more seriously about importing my data into JMP. I wanted to be able to go beyond the monthly time frame offered by the standard BodyMedia® web, Excel and PDF summaries.  I hoped to explore longer term trends and understand what factors might be causing the smaller weight fluctuations I still observed as my years of weight maintenance stretched on and I continued to log.  Like it is for so many of our customers, JMP was the perfect tool to help me move beyond standard reports to truly exploring my data.  If I had realized how much I would learn from tackling this seemingly unrelated analysis project, I would have started it sooner!  Helped along by snowy days and poor road conditions this winter, I dug into my initial data import challenge-automating the import of my multi-worksheet, Excel-formatted Activity Summary files.  I mapped out the steps I needed to take to get my data in from each of the multiple worksheets and collected snippets of JSL code including a very helpful loop example from a SESUG paper written by JMP Mac developer Michael Hecht. Soon, I was able to merge, clean, and format a table that contained all my data.

The scripting experience I gained from successfully tackling the Excel file import helped me build up enough confidence to undertake my next challenge-importing my food log files.  While I hoped to use a PDF to Excel conversion program, I found the structure of the PDF tables in the BodyMedia® files was not regular enough to convert cleanly to Excel using the tools I tried.  I converted my food log files to text instead and imported them into JMP.  With advice from JMP developer Craige Hales, I parsed out the information I needed using JMP’s JSL-based regular expression engine. When I got stuck, I depended heavily on online scripting resources and helpful suggestions from resident JSL experts Melanie Drake, Rosemary Lucas and Audrey Ventura. Upon completing the project, I decided to submit an abstract for Discovery covering import, processing and visualization of my data.  I know I will have more to share in future years, as I have much more to learn from my data, which I intend to keep collecting.

My Discovery poster shares more details about how I imported and prepared nearly four years of two different types of data collected with the BodyMedia® FIT activity monitor armband and its web- and app-based food logging software.  I hope you will join me at my poster session on Wednesday, September 17th to learn more about how I’ve used my own data to better understand the patterns in my weight loss and maintenance efforts.  If you stop by, you’ll also get a sneak peak of some of the new features coming in JMP 12 because I used many of them!    If you are a member of the JMP User Community, you can see a pdf version of my poster on the JMP Discovery 2014 community here

Article Tags