Minnesota is the state with the most Dairy Queen locations per person.
What's the farthest you'd ever have to drive to reach a DQ in Minnesota? How far would you have to go to get your birthday ice cream cake or a Reese's Blizzard on a summer day?
Inspired by the map of the "McFarthest" place from McDonald's, created by Stephen McWorley in 2010, I decided to create a similar map to look for Dairy Queen Deserts in Minnesota.
The DQ site lists 233 locations in Minnesota. Most are clustered around Minneapolis-St. Paul, where the majority of the state's 5.5 million reside. Beyond the twin cities, DQ locations are fairly evenly spread across major highway intersections and population hubs like Duluth, Fargo-Moorhead, and Brainerd. The biggest gap lies in the very northern part of the state, where population is sparse.
In order to identify the location farthest from a DQ, we'll use Haversine distance, which measures the distance between two points on a sphere (Earth). It can be thought of as distance "as the crow flies" because it doesn't take topographical features into account, such as mountains or road routes.
The location most remote from Dairy Queen is Waskish, Minn., population 118, 60.3 miles from the closest DQ.
The top 5 towns farthest from a DQ are all in the same region as Waskish - central northern MN.
The top 5 towns farthest from DQ | ||
Rank | City | Distance |
1 | Waskish, MN | 60.3 |
2 | Mizpah, MN | 52.0 |
3 | Northome, MN | 49.1 |
4 | Wirt, MN | 47.6 |
5 | Margie, MN | 47.5 |
Method
I geocoded the 233 Minnesota Dairy Queen locations using the Google Geocode API. I plotted them on the map using ggmap
and searched for a formula, package or script that would help me locate the spaces farthest from the points - the "DQ Deserts" - but came up short. There are plenty of packages and formulas for grouping points into clusters, calculating the shortest distance, etc., but none for finding the remotest point.
I tried a variety of approaches, eventually settling on calculating the center of triangles of Dairy Queens and throwing out any that had other locations inside the triangle. This helped identify "open" triangles of space. I then used the package geosphere
to calculate the Haversine distance between the remaining centers and locations to identify the Minnesota town farthest away from a Dairy Queen.
Limitations
This approach doesn't take into account are the areas of the state where no "triangles" covered. Areas like the very northwestern corner of the state, where three points couldn't combine to cover, are left out. Also, because the DQ locations focused on were all in Minnesota, it doesn't take into account locations just over the state border.
Computationally, doing this manually was very slowwwww. There are more than 5 million combinations of 3 of the 233 stores, which took about a half hour to process in R. A better formula probably exists. (If you have a better or faster way to do this, please let me know!)
Get the code here.
Header photo courtesy of Lorie Shaull.