V 1j is in post 1, with a change inspired by this PM from smpcoe:
smpcoe wrote:Subject: Holy Graily Bob 'n Grid
Hi Steve: Love it when you put the code changes up so we newbie programmers can learn this strange new language (coding).
As I was looking for what was new in Version 1i, the iLow & iHigh terms got my attention. I asked a friend of mine who trades strictly using candlesticks what he thought about it and he said it would be better to use the iClose instead of the iLow & iHigh. And he showed me why on GBPJPY H4 on March 22.
The iLow was too far awy from the iClose to work because when the next candle opened, it was 50 some pips above the iLow. The trades would have closed immediately using the 10 pip guess for SemaforRetracePips.
So I changed them to iClose & will let you know how it goes...
Hope this helps, Stan
I pulled up a couple of charts and applied the Quantum indi to them. Here is AU:
AUDUSDH4.png
You probably need to open the pic in a new tab and enlarge it so see it properly. Even better, download Quantum from post 1 and drag it onto a few of your own charts. Each Q box would have been a semafor signal until the hi/lo was broken and the signal redrawn.
It is hard to find a candle with a Q box that does not have a wick. This comes as no surprise. I am trading the H4, so a new hilo of 34 H4 candles represents over a week of trading and so will be a take profit level for a lot of people.
Using the candle closing price +- SemaforRetracePips would have kept a fair few trades going for considerably longer than using the candle hilo.
Also, my code was bollocks, so Stan's contribution would have helped a lot even if I had not adopted his suggestion. Thanks Stan.

I had forgotten to add SemaforRetracePips into the mix.
These are really easy changes for you guys to make yourselves - learn how in post 2 if you do not already know.
Change line 8 to:
#define version "Version 1
j"
Line 4683 is:
ClosurePrice = iHigh(Symbol(), TradingTimeFrame, 1);
and changes to
ClosurePrice = NormalizeDouble(iClose(Symbol(), TradingTimeFrame, 1) - (SemaforRetrace / factor), Digits);
Line 4690 is:
ClosurePrice = iHigh(Symbol(), TradingTimeFrame, 0);
and changes to:
ClosurePrice = NormalizeDouble(iClose(Symbol(), TradingTimeFrame, 0) - (SemaforRetrace / factor), Digits);
Line 4748 is:
ClosurePrice = iLow(Symbol(), TradingTimeFrame, 1);
and changes to:
ClosurePrice = NormalizeDouble(iClose(Symbol(), TradingTimeFrame, 1) + (SemaforRetrace / factor), Digits);
Line 4755 is:
ClosurePrice = iLow(Symbol(), TradingTimeFrame, 0);
and changes to:
ClosurePrice = NormalizeDouble(iClose(Symbol(), TradingTimeFrame, 0) + (SemaforRetrace / factor), Digits);
I know that some of you are using all this to gain some understanding of coding, so I will give you an insight into one of my thought processes.
I like to try to head potential trouble off at the pass. The info shown on your charts is a great example. It is not there for your benefit, but for mine. When something is not working properly and someone posts a chart picture, I can often work out what the problem is from the info shown on the chart. The user guide is another example. Yes, it tells new users what the bot is all about, but its principle function is that it allows me to snarl, "Read the UG, cretin" instead of needing to answer endless questions.
Have you noticed that the code changes involve SemaforRetrace not SemaforRetrace
Pips. You will find similar thingies dotted around my code. Take profits are calculated using TakeProfit not TakeProfitPips. Stop losses are calculated using StopLoss not StopLossPips.
I declare such variables to the user as an integer whose name ends with 'Pips'. This is to make it clear to noobs that we are talking about pips and not points. Trouble is, an integer variable cannot include a decimal point. Divide an integer variable containing the value 3 by 2, we are left with 1, not 1.5
Each of the integer variables such as:
extern int SemaforRetrace
is matched by a double a little further down the code, always in between two sets of long // comment lines, as in
double SemaforRetrace
I set SemaforRetrace to the correct value in OnInit - line 960 in 1j:
SemaforRetrace = SemaforRetracePips;
Look at the block of code starting at 952 shows how I initialise all the doubles to their partner integers.
Keep on getting into the code folks. You will not be sorry for doing so.

You do not have the required permissions to view the files attached to this post.