Performance of Semi-High Frequency Trading Algorithms in Python Based on Dark Pool Movements
Open Access
Author:
Fan, Mutian
Area of Honors:
Finance
Degree:
Bachelor of Science
Document Type:
Thesis
Thesis Supervisors:
Mihail Velikov, Thesis Supervisor Brian Spangler Davis, Thesis Honors Advisor
Keywords:
Computer Science Finance Trading Algorithms Dark Pools
Abstract:
Dark pools are hidden stock markets, which do not show trades before they occur as
opposed to a transparent market such as the New York Stock Exchange. Not much research has
been done in algorithmic trading based on dark pools; thus, the purpose of this thesis is to see if
dark pools are able to predict movements in the market and generate a positive return in the
market. This will be done using algorithmic trading done in the Python programming language,
through TD Ameritrade’s trading platform which allows foreign programs to access market
information.
The trading program will be set up using a web scraper to gather live dark pool data, as
there is a lack of historical information to back test an algorithm. Then, it will log this
information to be analyzed later. An analysis through looking at the assets of the algorithm given
a starting amount of $25,000 will be done and compared with the price movement on SPY
during the period of data collection. Risk-based analysis will be done using a Sharpe ratio with
the risk-free rate of the U.S. treasury yield. After the analysis, it was shown that the algorithm
performed extremely well despite heavy limitations on how many shares it could buy at any
given time. Although some assumptions were made for live market performance, it can be said
that dark pools are a valid way to make a good semi-high frequency execution algorithm.