Making Excel maps without VBA


If you want to make a choropleth/thematic map in Excel without programming perhaps conditional formatting is all you need. Here is how to do it:

  1. Select a few hundred columns and rows;
  2. Set width and height to 3 (more or less, depending on the resolutions you want);
  3. Set font size to 1;
  4. Place a map file over those cells and make it transparent (if possible, use a WMF file) so that you can see the cells and the map borders;
  5. In a new sheet, add a table with all the regions and some random data;
  6. Get back to the first sheet and for each cell within a region enter a lookup function and change cell background (the lookup must include the region ID);mapbase2
  7. Save your work and make a copy of this sheet;mapbase1
  8. Select a rectangle around your map and add a border;
  9. Choose a conditional formatting rule for the entire rectangle;mapbase
  10. Clear the existing cell background color;
  11. You should see a colored map using the conditional formatting rule.
  12. Inside the rectangle, merge a few cells and create a legend (in this case, I used percentiles to automatically update it);
  13. You can delete the overlapping file, but the maps will look nicer with the borders;
  14. Use the camera tool to copy the map to a new sheet.

Here is the sheet for the example above:

Make Excel choropleth/thematic map without programming.



6 thoughts on “Making Excel maps without VBA”

  1. That’s… a long way 🙂 the alternative to this is to use and Excel hack: when you copy some shape, then select a series in a chart and paste, all series shapes (e.g. columns, bars, or markers) are being replaced with this shape. You can create series for each shape multiplied by number of colors you want to display; set XY-chart and set correct coordinates for each shape to keep the map consistent; then hide / display correct series to display a shape with color needed using IF formulas and N/A value to hide series on a chart.

  2. I have to try that. For this example, I didn’t want to use VBA and/or shapes.

  3. Interesting approach, Jorge…

    However I have to say it’s really impractical. It’s more like an experiment than a real solution. The problem from my point of view is the huge amount of work you have to do here. I understand that you wanted to demonstrate what is possible, however, I would tend to use Dmitry idea here because that’s what VBA is made for: Simplifying and automating tasks, that otherwise would get daunting 😉

    just my 0.02


  4. Thanks for the comment Phil. Sure, but VBA is way out of many users’ comfort zone, even if this means spending hours defining the regions. Should the average Excel user learn basic VBA? Obviously they should.

  5. Unfortunately, VBA is virtually unusable in the latest versions of MSOffice, as it is no longer an option – unless running in “degraded” mode. Certainly no good on a MAC. I miss it somewhat, I must agree!

  6. I was looking for a way to use maps on Excel and I can barely believe that it’s possible to do such high-level documents without using VBA. I now have to find out how to do it with a map of France but I should find one.

Comments are closed.