Tax Treaties Over Time

It turns out that tax treaties are notoriously secretive. There doesn't seem to be a good free online database that even lists existing tax treaties. To build a basic map showing tax treaties over time I had to resort to scraping the UN Treaty Series Online, which proved to be very incomplete. Fortunately, after posting that on Twitter Martin Hearson pointed me to this awesome dataset he made with Action Aid (check it out here). So, instead of having to do some really painful webscraping I just used his dataset. I used the Google Maps API to get coordinates for each country, then plotted each treaty on a map using Plotly. I then used the various attributes coded for each treaty to produce different maps, with the lines color-coded according to the attribute's value. Here is one such map with the lines color-coded according to whether the treaty applies more source based taxing rights (green) or residence based taxing rights (red).

World Tax Treaties

I also made a map looking at Africa, where green lines represent Africa-to-Africa treaties, and red lines represent Africa-to-Not-Africa treaties.

Africa Tax Treaties

You can see some of my later maps (which are better in their presentation) over at Martin Hearson's blog. Those maps look at specific countries, as well as the spread of certain types of clauses, revealing more detailed information.

If you're really interested, I uploaded the (sloppy, somewhat embarrassing) code to github.