Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //
- // @author Eugen Covaci
- // @credits http://www.incrediblecharts.com/indicators/twiggs_money_flow.php
- //
- //@version=5
- indicator("Twiggs Money Flow", shorttitle="TMF")
- length = input( 21, "Period")
- tr_high = math.max(close[1], high)
- tr_low = math.min(close[1], low)
- tr = tr_high - tr_low
- adv = tr == 0 ? 0 : volume * ((close - tr_low) - (tr_high - close)) / tr
- tmf = ta.wma(adv, length) / ta.wma(volume, length)
- plot(tmf, color=color.green)
- hline(0, color=color.silver)
Advertisement
Add Comment
Please, Sign In to add comment