Introduction
EF4323 Algorithmic Trading Project Semester A 2024/2025 Instructor: Dr. DU, Jintao
In this project, we simulate the algorithmic trading business model, where a small group of proprietary traders tries to attract outside institutional investment by marketing their trading strategies and performance.
As a group, you have to study the target market (in this case: PD3), design your strategies, write the VBA codes, and test your strategy in the simulated market. You also need to collect the trading records and analyze the performance of your strategy given different market conditions. In the end, each group has to prepare a “Sales Presentation” that tries to grab the attention of potential investors.
Each group has to submit the following files to me through email before the deadline:
1. The Excel file that includes your VBA coded strategies (or Python codes on a txt file);
2. A well-written document that explains your strategies and analyzes the performance (no more than 15
pages, including everything);
3. Your PDF slides for the presentation;
4. All the data you collected (Zip it if it’s too big).
5. The representative traders list.
The deadline is:
November 19th, Tuesday, 8 PM.
The deadline will be enforced strictly. I will reply and confirm the reception of your submitted files. If you do not get my reply, it means your email did not get through. In that case, you may want to send it with another email account to avoid any delay due to technical reasons.
Note:
1. The server (port 10000) will close at 8 PM on November 19th. You should collect data before the server closes. You can collect data by downloading the performance report, using the RTD links, or saving data into a CSV file with Python.
2. The presentation will be on November 20th and 27th. Each team shall be given 12 minutes for presentation and up to 2 minutes for Q&A. All team members must show up and speak. Students who miss their presentation will be given 0 for the group project. Please do NOT brief the case again since all students know it. Directly discuss your strategies, performances, unique tests/techniques/trade-offs/concerns, etc.
3. After all the presentations, we shall run the simulations in class on November 27th. A team can choose how many members to participate in trading, and the list of traders must be sent to me before November 19th with your package. All team members in the same team will receive the average grade of all its participating traders in each simulation of the group project.
Design and Implement your “Algo”
The “VBA API Documentation.pdf” and “RTD Documentation.pdf” provide detailed guidance about how to set up your RIT client and Excel for algorithmic trading. Please read through them carefully. With your knowledge in VBA coding, you can modify the example code for ALGO1 and ALGO2 cases (in Canvas/Case Files folder) or design your new code to implement the trading strategies. There is no upper limit in the complexity of your code, but make sure it works well and all group members can understand it. I won’t be satisfied if you only use the sample codes or merely change some of its parameters. Below is a VBA learning site from Microsoft. You should start here if you have no coding experience before.
https://msdn.microsoft.com/en-us/library/xk24xdbe(v=vs.100).aspx
You are also allowed and recommended to use Python rather than VBA. Python is much faster and easier to implement complicated strategies.
In general, case PD3 provides profit opportunities from the following three types of strategies.
Arbitraging between Stocks and ETF: In PD3, as the ETF is designed to be UB + GEM, and there’s no restriction on short-selling, we have a perfect environment for arbitraging trades. After transaction fee, whenever ASK(ETF) < BID(UB) + BID(GEM) or BID(ETF) > ASK(UB) + ASK(GEM), arbitraging opportunity exists. You have to submit multiple orders at the same moment to capture these opportunities and control for the size of your orders too. You can either keep the arbitrage position to the market close when mispricing is cleared by settlement or close out your position when mispricing disappears during the trading session. In principle, you want to take as many arbitrage opportunities as possible. If your code is correct and fast, this strategy should be risk-free.
Arbitraging mispricing in Individual Stock: Similar to PD2, you can get a price interval estimate for the final fair value from the news for the two stocks. Arbitraging opportunities may arise when individual stock is traded out of the price interval.
Market Making: When there is no arbitrage opportunity, market making is a potentially risky profit channel. As a market maker, you make money when both your bid and ask are hit by others, and you end up with zero net position in any asset; you lose money when only your bid (ask) is hit, and then the market moves down (up) and never comes back.
When designing your code, you can either include many logic conditions in one “Super Algo” to take care of all profitable strategies or develop much simpler Algos to deal with specific tasks. It would help if you also tried to change the parameters in your code, for example, the aggressiveness of limit price, order size, etc. For each setting, run it at least ten times with the same parameters. If you have time, run as many times as possible to collect performance data under different market conditions.
Collect and Analyze your Trading Record
You should design your VBA code to take the record of essential performance metrics for each simulation. You can grab (but not be limited to) volume, profit, VWAP, and other summary statistics for your data analysis. Advanced VBA coders can also record transactions and prices second by second and then generate measures like volatility and price impact. In the end, you have to relate the strategies’ performance to these market conditions and analyze if any factors drive the results.
Some Advice
1. Start working on this project as soon as possible! I suggest you spend at least three days designing and testing your algorithm, at least three days running your code and collecting enough data, and at least three days analyzing the data and preparing the report and the presentation.
2. Share the workload optimally. It is efficient to divide the project into parallel tasks and distribute them among the group members.
3. Balance the effort and time between designing the strategies and collecting/analyzing the data. These two dimensions are equally important to the quality of this project.
Prepare the PPT Slides and Formal Presentation
In the last meeting of this semester, each group has to do a formal “sales presentation” for their strategies. Imagine you are trying to get external investment for establishing a proprietary trading firm based on your quantitative strategy, and your audience are potential investors trying to select a group to invest in.
You have to impress your audience with excellent performance, attractive slides, and communication skills during the presentation. Each group will have 12 minutes for the presentation (only clarification questions allowed in this period) and then 2 minutes for open Q&A with the entire audience. The audience should pay close attention to other groups’ presentations and try to question their results.
You are not allowed to read from notes during your presentation!
Grading and Related Policies
The total weight of this project is 56%, of which 20% goes to the six in-class simulations, 11% goes the quality of your codes and writing report, 5% goes to your presentation score by the instructor, 10% goes to your prediction score, and 10% goes to the popularity score.
Grading of code and report:
First, I will read and run your code and check if it works the same as described in your report. So please make sure your code is ready to run before submission. If your code cannot perform the functions claimed in the report, you will not get any points for this project.
I will value the creativity of your strategy and the depth of your code. I will also value the organization of your report. In general, your goal is to design the best strategies within your skillset and present your performance in a very informative way. Your report must be “reader-friendly” and clearly summarize the strengths vs. weaknesses of your strategies.
Grading of presentation:
We are going to grade the presentations “democratically.” Each group will rank all the other groups from 1 (the top) to 15 (the bottom). Then I will collect all the grading. The average ranking that each group receives from the entire class will decide their popularity grade. The closeness of each group’s rankings of the whole class to the actual rankings of the simulation performance will determine their prediction score.
Policies:
1. Learning how to work as a team is an implicit task for this group project. It is your responsibility to make sure the group works together toward the goal and group members contribute comparably to the results. I will not intervene in matters within your group, and I will not act on any complaint about free-riding.
2. You must design your strategies and write your code by yourselves. You must NOT outsource the task from the internet or anyone out of your group. Once found/reported and confirmed, such activities will result in a FAIL final grade for EVERYONE in the group.