Wednesday 11:50 a.m.–12:20 p.m.

Regulating the Securities Market with Django and Pandas (and how to_excel() may have saved the day)

Christopher Clarke

Audience level:



Developing applications for civil service organizations can be uniquely challenging. The presentation discusses our experience with MASS a market surveillance and monitoring application developed for the TTSEC. MASS is based on Django and Pandas. We highlight not only the techinal aspects of the solution but also address the HR and organizational factors that impacted on the project


In 2011, the local stock market was hastily forced to migrate to a new trading platform that provided a very limited set of trade surveillance and monitoring tools. In response to this situation, we were asked by the Trinidad and Tobago Securities and Exchange Commission to develop MASS, a web based, market surveillance and monitoring application that based on Django and Pandas.

We start the session by looking at some of business and management challenges we faced in implementing the project. Starting with the fact that it took more than a six (6) months to get the formal sign off on the project. We believe that this discussion will prove to be instructive as these kinds of issues often face those building solutions for heavily bureaucratic civil-service type organisations. We then go on to outline the key elements of the solution architecture of MASS, including the thinking behind key design decisions, the components selected and some of the key trade-offs that we had to make. We also include in this section, a discussion of the open source reusable Django app django-pandas which emerged from the project. We then go on to review our somewhat unsuccessful attempts to extend the functionality of the MASS with an IPython notebook client and our attempts to introduce more sophisticated statisical and data mining techniques into the analysis of local trading patterns. We attribute these failures not just to technological issues but also to to our failure to take into account various organisational, cultural and human resource factors. Finally, we look at how Pandas facility for interfacing with standard MS Office applications like Excel is proving to be the gateway drug for introducing this group of non-techinial users to tools like IPython notebook, the Django ORM and even the Python hacking