The “Lag Reduce Factor” is a simple method to the reduce the delay to a data series. In this case it is applied to a simple moving average. It could be changed with other input (change MA value with any of data serie of your choice). The factor to add more or less weight to the delay elimination is the “RLfactor” setting (default = 1.3).
While it is different to a ‘zero lag’ calculation method, it could be classified in the same category.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
//PRC_MA Lag reduce factor | indicator //26.08.2018 //Nicolas @ www.prorealcode.com //Sharing ProRealTime knowledge //original idea from scriptor (MT5 indi) // --- settings period = 20 RLfactor = 1.3 // --- end of settings MA = average[period](customclose) MLR = exp(RLFactor*log(MA / MA[1]))*MA RETURN MLR coloured(148,02,11) style(dottedline,3) |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials