First post - Food Security Visualizer

I created a flask app that shows FAO data for food security with several interactive maps.

3/30/20232 min read

The idea for this interactive map started over a dinner conversation with my family, after I had shown them a different python app which I had developed. Based on that conversation, I decided to attempt to create a visualization tool that could show map data in an accessible and useful way.

FAO maintains a great statistics database (, but when I had accessed it, there was no easily accessible way of visualizing the data. Later, after much digging around on FAOs webpages, I found that they have similar mapping visualizations, but with different visualization techniques and functionality.

The visualization tool is meant to be a nice way to explore Food Security data from FAO. The slider is programmed so that it shows green on the slider for years with available data and red for years without data availability. The map itself is interactive, where you can click on countries to see exact values of data points, zoom in and out, and drag and drop your way across the map. 

I only started really using Python in February (I have previous experience with R and Javascript), so it was a challenge to make this functional and web accessible. My first several versions were moderately functional but either lacked certain functionality (clicking), or were terribly slow to load. The version you see now took many iterations and was the result of a lot of testing and learning. All of this was made possible through the use and re-use of Chat-GPT. I used Chat-GPT through all points of production, from creating code, to editing code, troubleshooting, debugging, using different libraries, connecting the application to the web. In reality the list is much longer, especially during the pain-point which was web app development. 

Up to the point where I needed to make the app web-enabled, everything was difficult but steady sailing. Two steps forward and one step back. But once I tried making the app work with a website, I hit definitive roadblocks. Who knew that taking a python app and making it web enabled would be such a challenge. To be fair, I think the process itself would be much easier knowing what I know now, but that was the point in a lot of this exercise, to learn the diverse functionality and libraries of python. 

In the end, I ended up making my Python script a flask web-facing interface that relied on HTML to serve you the visuals you see now. But wait... the fun doesn't end there. It was a challenge to find a decent service that could allow me to embed this web app into my pre-existing personalized web-page. In the end, it was google app engine to the rescue. Shoutout to google for having such a great multitude of tools through which individual developers can learn and grow. Basically I was able to have google host the APP you see, and, the rest is history. It's worth mentioning that the interface can be a bit slow sometimes (there is a lot of data to process).

Libraries used: pandas, folium, plotly and json 

Languages used: Python, flask, html, javascript