Close Location Value (CLV) Indicator

 

Hi,

I am rather new to MT4 and I would appreciate any help with the following:

I want to create a Close Location Value (CLV) Indicator . I want to access this indicator from a MT4 script by calling it as any other indicator such as iRSI or iMACD. In other words, call "iCLV" with input parameters iCLV(Symbol(),Timeframe, interval, MA period). CLV = ((Close - Low) - (High - Close)) / (High - Low), where Close, Low and High can also be for an interval, not necessarily for a single bar. "MA period" is to have a built-in moving average smoothing of the indicator.

Many Thanks.

 

You can only call indicators by using the iCustom function. If you call indicator from script the indicator will be removed when the script finish doing its work. The format you want can be found here. For more info about creating custom indicators start here.

Reason: