Example—Live Samples


This is a live example to demonstrate how to create an analytics extension in javascript that can communicate with third-party APIs and add additional calculation functions to Tableau. It shows you how to use the Analytics Extensions API to do things like convert money from one currency to another and how to convert dates to strings based on a specified format. Test it out for yourself or remix it to create your own! For more information, see the project on Glitch.

Available example functions include:

1) Currency conversion (Powered by Open Exchange Rates)

2) Language translation (Powered by Yandex)

3) Drive distance between locations (Powered by HERE)

4) Drive time between locations (Powered by HERE)

5) Date Formatting (Powered by Moment.js)

6) Statistical Mode

7) Internal Rate of Return (IRR) financial calculations (Powered by Finance.js)

Example of IRR function used in a Tableau calculation