Last active
October 16, 2019 03:30
-
-
Save bongkook/c204944f0d8956d29183dd446f6cdc85 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//@version=2 | |
study("Heiken Ashi MTF") | |
ha_t = heikinashi(tickerid) | |
res = input('60', title="TM 1") | |
ha_open = security(ha_t, res, open) | |
ha_close = security(ha_t, res, close) | |
ha_dif = ha_open-ha_close | |
ha_diff=iff(ha_dif > 0, 1, iff(ha_dif<0, 2, 3)) | |
res2 = input('240', title="TM 2") | |
ha_open2 = security(ha_t, res2, open) | |
ha_close2 = security(ha_t, res2, close) | |
ha_dif2 = ha_open2-ha_close2 | |
ha_diff2=iff(ha_dif2 > 0, 1, iff(ha_dif2<0, 2, 3)) | |
res3 = input('D', title="TM 3") | |
ha_open3 = security(ha_t, res3, open) | |
ha_close3 = security(ha_t, res3, close) | |
ha_dif3 = ha_open3-ha_close3 | |
ha_diff3=iff(ha_dif3 > 0, 1, iff(ha_dif3<0, 2, 3)) | |
plot(15, title="TF1", color=iff(ha_diff==1, red, iff(ha_diff==2, green, white)), style=circles, linewidth=5, join=true) | |
plot(14, title="TF2", color=iff(ha_diff2==1, red, iff(ha_diff2==2, green, white)), style=circles, linewidth=5, join=true) | |
plot(13, title="TF3", color=iff(ha_diff3==1, red, iff(ha_diff3==2, green, white)), style=circles, linewidth=5, join=true) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
[TVExtBot]HeikinAshi+Ichimoku Indicator(Alerts)