Our World Statistics Day conversations have been a great reminder of how much statistics can inform our lives. Do you have an example of how statistics has made a difference in your life? Share your story with the Community!
Choose Language Hide Translation Bar
Using a space filling design and Google Maps to plan my commute: Part 2

Morning commute with traffic

I did learn some things about my commute using a space filling design. (Photo by Geoffrey Arduini via Unsplash: https://unsplash.com/geoffreyarduini)

In my previous blog post, I created a 150-run space filling design to collect travel times over various departure times in the morning and evening. I wanted to see if I use this designed experiment to  learn something useful about my commute.

Google Maps gives a range of times for a given trip – I’ve taken the midpoint for each of these. While I might want to validate at a later time just how accurate these times are, using this computer-generated response means I can collect all this data in one sitting. If I instead collected the data based on the actual drives I’m making, it would take me 30 weeks and the data would be much noisier. My boss also told me that he might have issues with my commute being dictated by data collection for a designed experiment.

So, I took the fast and prudent approach and collected the data from Google Maps. Now what?

After some data exploration, it’s not surprising that to try and make Fit Model work, I’d probably want to try higher powers, maybe some spline effects, transformations, etc… but all I really want is a fit that captures some of the intricacies while giving me access to the Prediction Profiler. A Neural net seemed like the perfect choice. I wasn’t worried about overfitting so much as getting appropriate results – and in this case I could cheat because I had a sense of what the fit should look like by investigating morning and evening times separately. I tried various choices of nodes and validation methods through use of a covering array, to ultimately use 10 TanH and Gaussian nodes in the first layer and 10 Linear nodes in the second with validation through Random Holdback. Instead of telling you what I see in the results, why not just share it with you?

Here's what my Profiler looks like as a static image, but you'll want to explore the interactive version; click in the graphs or enter different values for Day, morning departure or evening departure.


I created this Profiler by saving the profile formula in the Neural platform, and then saving as Interactive HTML 5 using that prediction formula under Graph->Profiler.

What I Learned

I’ll let you play with the results, but a couple of things I found interesting that corroborate with trends that I’ve observed:

  • For Monday to Wednesday, leaving by 7:30 a.m. gives the shortest commute. Every 10-minute delay after that costs roughly an extra minute on the road.
  • On Thursday and Friday, the longest predicted commute is for departures at 8:07 a.m. and falls off from there. The commuting time at 9:00 a.m. is roughly the same as at 7:30 a.m.
  • The afternoon commute is worst at around 5:30 p.m. Monday through Wednesday. On Thursday and Friday, the longest commuting time results from leaving a little before 5:10 p.m..
  • The Thursday and Friday commute generally takes less time than commutes earlier in the week.
  • Final Thoughts

    I had a lot of fun using the new JMP 12 features in space filling designs and the Interactive HTML Profiler. While the accuracy of the Google Maps travel times remains to be seen, I was a bit surprised with the variation in the predicted commuting time from day to day.

    Another interesting experiment would be to add another factor to compare different routes. a future blog post will show how to add restrictions to morning and evening departure times. After all, if you leave later in the morning, you will probably also need to leave later in the evening.

    Article Labels

      There are no labels assigned to this post.