in case you didn't get a response on your request yet, here's the code you're looking for. Copy and paste to a new study in ToS and give it a name.. should do the trick. i can send you the .ts file if that's easier for you,
hope this helps,
input Alert_Range = 1.00;
Def Candle_size = High - low;
Def UpCandle = Close > Open;
Def DownCandle = Open > Close;
plot Signal_Up = Alert_Range > 0 and UpCandle and Candle_Size >= Alert_range;
plot Signal_Down = Alert_Range > 0 and DownCandle and Candle_Size >= Alert_Range;
AddChartBubble(Signal_Up or Signal_Down, If signal_up then high else low, if signal_up then "" + high else "" + low, Color.yellow, signal_up );
Thank you for the help in my study this exactly what I need. If possible can you make a few changes.
1. I need to add a sound alert
2. The problem I am having is if I’m on EUR/USD and I set the alert to .00012 when I switch to EUR/JPY it triggers way to many times so I have to go in and change the alert #.00012 to .00015 Do I have to make setting for each forex or is there a way around this.
3. I am using 1min charts so all I really need is for the alert to trigger in 4 pips that way I can use it for all forex.
so if there is a way to rearrange the code to work off of pips that would be perfect.
1 - added the alert and an Open_Alert input setting ..
2 - 2 ways i see to go around what you need here
first, either you have a set of preferred pairs, each with a different "Alert_bar" setting you use, then we can build a conditional choice around that in the script .. for example (in simple language):
if we're in EUR/USD --> use Alert_Bar value of x
but if we're in EUR/JPY --> use Alert_Bar value of y
... and so on ...
otherwise use Alert_Bar generic value of z
second approach, if there's some sort of a formula that we can use, to calc the proper Alert_Bar value (or come close to it then override as/if needed) based on some variables of the price on the "current chart" regardless of which pair.
for example, in my PriceLevels indicator (EliteSection) i use a generic initial range of 0.5% of the midpoint value of the chart. and there's a setting to over-ride this from the study setting. this way i only need to enter a manual value if the default 0.5% (which should cover many scenarios) doesn't work or i need to see other levels increment.
your choice, we can do either ways.
but i'm not a FOREX expert.. so i can't suggest an approach.. i don't even know what a pip is .. (yes i heard the term.. an interesting word).. but do you mean there's a common Alert_Bar length/range that you need to trigger that alert/signal? then we should use that and if it's up or down, we show the arrows & price accordingly.
in the range charts in TOS, and you can set the range to any value you may need. it seems to work with FOREX .. don't know. it's a different view that i'm mentally not used to .. and my brains get confused so i stick to classic time charts and don't play with it that much.. you may try to give it a shot.
Thank you again for taking the time to help me with this study I think you have solved this study the only thing I would say is I trade forex as well and I'll take your recommendation on how to approach this study.
A pip is simple the lowest amount a forex, stock, indices can move in so if you had 1.9656 the pip would be the 6 its always the lowest number in the price.
I will be posting a new challenge study today please check it out I think its going to be huge if it can be done especially for forex trading.