Best Structure for a Trading Model based on Stock Indices
Show older comments
Apologies if this sounds very basic but I am completely new to Matlab and would greatly appreciate if someone could let me know if I am on the right track with regard to the data structure I plan to use for my project:
- I plan to generate a model for buying/selling stock indices and tracking the return vs a simple buy and hold strategy. - Inputs are excel sheets with historic end-of-day data (Open, High, Low, Close, Volume) for Dow Jones Industrial Average and Nasdaq Composite. I have also another sheet which contains daily market breadth data such as Advancing issues, Declining issues, etc. - I then plan to calculate several indicators such as MACD, RSI, Moving Averages, On-Balance-Volume (OBV), etc. for every index and day - Based on the above price data and the calculated indicators I want to create specific buy and sell rules. There will be SEVERAL different buy and sell rules and in addition to an overall buy/sell performance for the model I would also like to measure the return of each individual buy or sell rule, max drawdown, etc. For your information, a "sell" would be closed out once any of the "buy" rules gets triggered and vice versa.
Once it's up and running I would like to do statistical testing and be able to play around with adding/removing individual rules or varying certain parameters.
So far I believe the best modeling option would be using the DATASET format (Statistics Toolbox) with the date as the key variable to link the individual sheets. Would you agree or is there a better way to implement the model? How would you create the buy and sell rules? Would you use a separate DATASET for this or just program code?
If anyone has a simple template file for this to learn about the structure or knows where to find one, this would be much appreciated!
Thanks a lot!
Accepted Answer
More Answers (0)
Categories
Find more on Financial Data Analytics in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!