TradingView
ZenAndTheArtOfTrading
5 gen 2019 01:27

Higher Timeframe EMA 

AUD/JPYOANDA

Descrizione

This script plots a higher timeframe EMA to your chart.

You can specify the timeframe and the length of the EMA in the settings.

This chart demonstrates the 5-minute 50EMA (black) combined with the 1-hour 50EMA (colored) on the 1 minute timeframe.

Note di rilascio

Fixed error in code that did not allow user to change EMA length, added Offset setting.

Note di rilascio

Minor improvements

Note di rilascio

Minor improvements

Note di rilascio

-
- Converted to Pine Script v4
- Added smoothing or stepped option

Note di rilascio

-
- Changed offset default to zero

Note di rilascio

-
- Changed lookahead to off.
- Removed offset.

Note di rilascio

- Fixed repainting issue

Note di rilascio

Updated to Pine Script v5

Note di rilascio

Fixed potential repainting issue
Commenti
ujeenine
Thanks a lot! I really respect your contribution!
ZenAndTheArtOfTrading
@ujeenine, You're most welcome! Glad to be of service. Good luck with your trading :)
Charles_Trades
I am using V4 and your 7th line keeps giving me the error: Undeclared identifier 'resolution';

Is there a new way to write this in V4? Since yours says V3.

Thanks!
ZenAndTheArtOfTrading
@Charles_Trades, Hey Charles! Yes, in v4 that line of code must be changed to say this: type=input.resolution

Let me know if that doesn't work. Good luck with your trading :)
ZenAndTheArtOfTrading
@Charles_Trades, I actually just released a small update for the script. I converted it to v4 and added a "stepped" or smoothed option for the EMA on lower timeframes :) have fun!
neillswap
Thanks a lot sir... solved my problem for working with higher and lower timeframes at the same time ...
TWENTYTRADER
hey thanks !!! I love your youtube channel , you taught me how to write my own scripts!! thanks a million!!
ZenAndTheArtOfTrading
@TWENTYTRADER, you're welcome! Awesome to hear that. Good luck with your trading and coding :)
PLPTrade
Thanks a lot for this, this has improved my trading results a lot ...

i am also trying to include High low in this... however i am not that good in getting it correct... can you please help
ZenAndTheArtOfTrading
Hi @PLPTrade! That's great to hear :) if you just want to draw the previous day's high and low over the top then this code should do the trick: pastebin.com/vUvW6npn
Altro