Data Visualizing Global LPG Trade
The skills the author demoed here can be learned through taking Data Science with Machine Learning bootcamp with NYC Data Science Academy.
App: Beta Shiny Application Github: Github
Data shows 95% of the world's goods are transported via the ocean including a variety of cargo and essential energy resources. Liquid petroleum gas, commonly known as LPG or referred to as propane, is just one of these energy resources. LPG is mixture of flammable gases often used for heating, cooling appliances and cars in developing countries who lack the energy infrastructure for more common types of fuel.
As these developing countries grow, the volume of LPG transported has followed to meet these developing countries increasing energy demands. The volume of LPG transported worldwide has increased drastically over the past 3 years and the order book for new vessels will account for 35% of all vessels on the water when completed by 2019.
These trends substantiate the importance of this growing commodity type and this application was develop to better map global LPG transportation at a country and vessel level in order to assess the transformative patterns that have occurred over the past few years and dramatically visualize this data which has existed mainly in only private excel sheets.
Furthermore, this project lays the foundation for a dashboard that could not only visualizes historical data as it does in its current state, but could merge this import/export data with automated production and ship position data to predict future over and undersupply of LPG in various regions (see next steps section for more) and give ship owners an edge positioning their open vessels in this increasingly competitive market.
Probably the most noticeable trend in the last five years in global LPG transportation is the the dramatic change in which countries export the most LPG. The Far East region including primarily China, Japan, South Korea, and India have remained consistent as the largest importers of LPG year after year with an increase in Indian imports and a decrease in Japanese imports over the last few years. Although the volume of imported LPG has increased among these countries, the countries have remained fairly consistent.
The same however cannot be said about countries which export LPG. Over the last five years, the greatest export countries of LPG have shifted dramatically. Five years ago, countries within the Arabian gulf region including Qatar, UAE, and Saudi Arabia dominated the global exports, while now the U.S. has become the single largest exporter of LPG (up from nearly zero exports in 2011). For those in the industry, this trend is common knowledge, but again this known trend has probably not been visualized in such a dramatic mapped fashion or through flow charts that adjust dynamically over time.
The real power of this application exists not in its current state, as a visualization dashboard, but through the potential it has if further data sets are compared against this preexisting data. If I were to get access to APIs that automatically feed in the real time data for the pre-existing data sources, the current positions of all global VLGCs with their ballast or laden (empty or full) statuses worldwide, and LPG inventory and production data at a country level, it would not be very difficult to assess present and future over or under supply of LPG globally.
Comparing these data resources against the flow data the application already presents would allow a user to assess the number of VLGCs in each region or country compared to the inventories and production levels for that country both historically and forward looking. Predicting future over or under supply of VLGC and inventories has amazing potential because ship owners could then make more accurate speculations on where to send their open vessels.
When starting this project, I knew I wanted to plot LPG trade data from IHS Connect (see Data section) which has lifting information indicating the volume traded as well as the source and destination countries of every voyage where a vessel was carrying LPG. This was a great start, but the first hurdle was how to obtain coordinate data for countries in order to then plot the arcs between countries you see on the map tab. To do this, I merged this lifting data with the Google countries dataset (see Data section) both on the source country and the destination country columns to assign a latitudinal and longitudinal center for each country.
With this accomplished, I then created a reactive function to filter this lifting data based on user input from the date slider. This was done using observeEvents to update reactiveValues that could then be accessed within other reactive elements in the server.R file. The filterData reactive function filters the reactiveValue for data
values$data based on the country dropdown selectors
input$filter,which then updates the map, flow chart, and data table reactive components. However, because this filterData function doesn't change the reactiveValue,
values$data, the list of all countries still within that date range is still accessible and can be used as the selection options in the dropdown country selector
For more information, read the inline comments within the files of the github repo
View Github: Github
Written in R, using R studio. Deployed using ShinyIO.