Before the Coronavirus, the killing of George Floyd and the “shenanigans” surrounding the current presidential election together eclipsed virtually every other issue, I began a data visualization project examining the comparative benefits and demerits of levying tariffs for the purpose of raising revenue versus protectionism. In this article, I will revisit that project, and share the insights I gained from it.
Before jumping into the project itself, I think that it would be prudent to review what classical economic theory has to say about levying tariffs. The 19th century French economist and legislator, Frédéric Bastiat (pictured above), satirized the practice of enacting tariffs to protect local industries from competition in his now famous Economic Sophisms. In Chapter VII of the Sophims, Bastiat relates the Candlemakers’ Petition to blot out the sun in order to create a greater demand for artificial light. If this sound familiar, Mr. …
In a previous article, I discussed the planning processes and initial implementation of the Citrics web application. In particular, I related the need to clean up the API, removing superfluous routes so that it would be readable be more readable for the current web development team and the team that will take over the project this November. I also related my idea to use route referencing and cache-in on the power of our PostgreSQL database, the former reducing the number of redundancies in our code, the latter reducing the number of calculations performed by the API.
I believe my reader will agree after viewing the before implementation and after implementation screenshots of our API, that the current API is much cleaner. …
Citrics is the first web application I have worked on with a production window longer than a single week. The app is designed help answer a common question plaguing digital nomads, where should I go next? Working as a data scientist on a team with seven other people, we set out to build an app that would allow users to compare certain key metrics for various cities in the United States — hence the name Citrics = “City” + “metrics”.
The application is actually composed on three main components, the web application itself, the Data Science API we built for the application to call from, and a PostgreSQL database which the DS API references. The latter two were hosted on Amazon Web Service, with the DS API utilizing the AWS’s Elastic Beanstalk Service using FastAPI. …
I have always felt that to be successful in any field requires the ability to not only use tools which others have built, but also to have at least some basic knowledge of how those tools work under the hood. Data Science is no exception. Those of us who do work in Python have been richly blessed by the folks who put scikit-learn together, but how many of us have actually taken the time to attempt to replicate one of their functions from scratch, let alone the hard way? By the hard way, I mean researching the algorithm yourself, either on YouTube, or, for the truly hardcore, by reading through a statistics textbook, then attempting to implement the algorithm, step by step without reference to any outside code. …