Australian (ASX) Stock Market Forum

Metastock Formula for bar strength indicator

Joined
15 September 2022
Posts
12
Reactions
2
Hi Guys I hope you all are well.


Could someone please help me to write this code for Metastock?

First, we want to establish the interbar strength—how we calculate that is (close-low)/(high-low) * 100%. This should give us a percentage where below 49% is red and above 50% is green.

then, use the average of the last 3 bars (so you need to divide the figures of interbar strength percentage of the last 3 bars by 3), and if they are above 50%, paint the bars green; if they are below 49%, paint the bars red. I hope this makes sense.

I would appreciate it if someone could help me to write this code.
 
Top