Awesome thank you for your interesting and well documented code , Looking forward to getting it to work . There is at least one trap with for newbies , that is to change the target symbol on line 92 to your brokers symbol for sp500 ,also on line 84 to match the stock symbols your broker has.
what should line 286 'Our Model Parameters return? I get [-nan(ind)], the rest seems to work perfectly.
Awesome thank you for your interesting and well documented code , Looking forward to getting it to work . There is at least one trap with for newbies , that is to change the target symbol on line 92 to your brokers symbol for sp500 ,also on line 84 to match the stock symbols your broker has.
what should line 286 'Our Model Parameters return? I get [-nan(ind)], the rest seems to work perfectly.
I was hopefull this might actually work. Thanks to the auther for sharing it regardless.
cannot load indicator 'Relative Strength Index' [4302]
cannot load indicator 'Moving Average' [4302]
cannot load indicator 'Williams' Percent Range' [4302]
cannot load indicator 'Commodity Channel Index' [4302]
I understand indicators should automatically be loaded and displayed.(fails)
I manually placed the indicators on the chart and even created a template with all indicators included. Even when every stock's chart is open and all indicators placed on chart manually, the EA fails to read indicators on it's own.
I was hopefull this might actually work. Thanks to the auther for sharing it regardless.
cannot load indicator 'Relative Strength Index' [4302]
cannot load indicator 'Moving Average' [4302]
cannot load indicator 'Williams' Percent Range' [4302]
cannot load indicator 'Commodity Channel Index' [4302]
I understand indicators should automatically be loaded and displayed.(fails)
I manually placed the indicators on the chart and even created a template with all indicators included. Even when every stock's chart is open and all indicators placed on chart manually, the EA fails to read indicators on it's own.

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Check out the new article: SP500 Trading Strategy in MQL5 For Beginners.
Discover how to leverage MQL5 to forecast the S&P 500 with precision, blending in classical technical analysis for added stability and combining algorithms with time-tested principles for robust market insights.
A list of the companies included in the index is easily accessible on the internet. We can leverage our understanding of how the index is composed to help us create a trading strategy. We shall select a handful of the largest companies in the index and use the respective price of each company as an input to an AI model that will predict the closing price of the index based on our sample of companies that hold proportionally large weights. Our desire is to develop a strategy that blends AI with trusted, time-proven techniques.
Our technical analysis system will employ trend-following principles to generate trading signals. We need to incorporate several key indicators:
Author: Gamuchirai Zororo Ndawana