The Big Mac Index Table - Table Contest Submission

The Big Mac Index Table

Authors: A. Calatroni, S. Lussier & R. Krouse

Abstract: Our goal for the 2020 RStudio Table Contest was to learn and practice with the gt package. In particular, bring interactive figures within the table.

Full Description: Our goal for the 2020 RStudio Table Contest was to learn and practice with the gt package. To do so we decided to focus on the following aspects:

  • Include interactive figures within the table. For this, we chose the echarts4r package to create interactive graphics with Echarts Javascripts, albeit other packages would have also worked (ie. Plotly, highcharter, etc.)
  • Include images, either through a GitHub repo (flags) or Wikimedia commons scraping (maps)
  • Include as many HTML tricks as necessary to improve the overall readability of the table (for example HTML color of headers, icons, spanners, hyperlinks, currency symbols, scale up the image size (maps) on hover, etc.)
  • Include footnotes, in particular a footnote color legend for the color column, an HTML details tab to display in an inconspicuous way the R session information, and font awesome icons for github and twitter hyperlinks).
    Include CSS with the new feature opt_css to improve the tables aesthetics, especially in light of the interactive graphics tweaking.

In short the Big Mac Index is published by The Economist as an informal way of measuring the purchasing power parity (PPP) between two currencies and provides a test of the extent to which market exchange rates result in goods costing the same in different countries. It seeks to make exchange-rate theory a bit more digestible. The magazine's latest version (July 2020) of the The Big Mac index interactive currency comparison tool.

Table Type: static-HTML & interactive-HTML
Submission Type: Single Table Example
RStudio Cloud:
DT package used:
gt package used: true
reactable package used:
flextable package used:
huxtable package used:
kableExtra package used:
Other packages:


This is a really cool table. Just a minor point that I observed. In the "Latest Prices - Local" column, the currency symbols seem out of order. For example, the Japanese Yen symbol is used for Brazil while South Korea has the Euro symbol etc.

But overall this is an amazing table and will definitely look at the code to myself learn the HTML, CSS and Javascript tricks used here. Thanks for sharing!

Thank you for your comment, indeed a misplaced arrange created the mismatched between currency name and symbol. We have fixed the issue.

1 Like

Very cool. +1 for echarts4r, beautiful library