In my last month article I described the general ideas of how I decided to automate the strategy presented by the member BlueDragon, as I mentioned I saw a great potential in it. In this article, the last of this year, I want to show you the practical part as regards the implementation of the code. Just picking up on what was described in the previous article, we will analyze step by step the generated code to build the strategy. I'm not going to show how a strategy is made from scratch, as it is already well explained in previous articles from other community members.Let us start analyzing the code for each point described in the previous article:1 - Pivots Calculation:I will start by presenting the main piece of code of the strategy, it is here that the pivots are calculated according to the periods used : H4 - Daily - Weekly and Monthly. What this piece of code does is get the history of the last candle of each period and then calculate the (H+L+C)/3. Then it checks the difference between the closing price of the candle and the pivot calculated. If the difference is greater than or equal to the defined, the conditions are set to open trades at the beginning of the next candle in…
Read article
Translate to English Show original