Peak HiLo MT5

Post Reply
TableTop
Trader
Posts: 84
Joined: Wed Oct 20, 2021 12:36 pm

Peak HiLo MT5

Post by TableTop »

Attached is a version of Steve's Peak HiLo indicator that I have migrated to MT5. A few things to consider before using it.
  • I am a novice coder.
  • My MQ5 coding is limited to creating a handful of scripts and indicators that I find useful (and a few of them even work!)
  • I utilise LLMs (but I have a sensible workflow that catches some of the more obvious LLM mistakes and hallucinations).
  • Reverse engineering someone else's code is very hard (IMO), even when it is well commented.
  • I have only done limited testing, i.e., tested that it works the way I use it (which is as described in Steve's Peak HiLo PDF documentation).

So, please be aware of this and test thoroughly. I will attempt to fix bugs, but my time is limited for the next couple of months, so please be patient.

I have also attached an overview of the approach taken to migrate the code. It outlines the main refactoring steps undertaken, and may be useful if someone wants to understand why things were done a certain way.
You do not have the required permissions to view the files attached to this post.
Last edited by TableTop on Wed Aug 06, 2025 5:19 pm, edited 1 time in total.
TableTop
Trader
Posts: 84
Joined: Wed Oct 20, 2021 12:36 pm

Re: Peak HiLo MT5 v1.1

Post by TableTop »

This version adds buffers to display the direction of each timeframe in the data window (making it easier to use with an EA).

4 buffers, 1 each for Highest, High, Medium and Trading timeframes. A buffer value of 1 is Long, -1 is Short, and 0 is no signal.

The buffers are only correct for the current bar. The calculation for the buffer is based on closed bars, so I think this is OK for use in an EA. Prior bars (ie, any candles greater than index 0 are not calculated, and any figures you may see in the Data Window should be ignored). I am not sure if the historical values are needed or whether I'd be opening a can of worms (which I don't want/need to tackle today).

I am sure there is a more elegant way of doing this.

Edit: updated indi in post 1
Last edited by TableTop on Wed Aug 06, 2025 5:20 pm, edited 1 time in total.
TableTop
Trader
Posts: 84
Joined: Wed Oct 20, 2021 12:36 pm

Re: Peak HiLo MT5 1.11

Post by TableTop »

Fixed a bug that stops Peak HiLo from running in the MT5 strategy tester.
Updated in post 1
Post Reply

Return to “Indicators”