Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
Does anybody know how how to create a study for TOS that when a candlestick reaches or passes a specified size a mark is placed on the chart along with the price, I need it to work on 1m charts.
Let me know if there is a TOS import for this already or if some one can write the code down for me thank you.
Example:
98.7
[]
95.3
[]
Forget about the number for one second I would like for singal to trigger when the legnth of the cadle reaches a specified size no mater if its going up or down.
If the [] candle green up length is 10 or above it will paint a up arrow above the candle on the chart.
If the [] candle red down and its length is 10 or above it will paint a down arrow above the candle on the chart.
The numbers on top of these candles is just the buy price but it would be nice to have this.
Can you help answer these questions from other members on NexusFi?
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,
RedK
-----------------------------------------------
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;
Signal_Up.setPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_up);
Signal_Up.setDefaultColor(color.cyan);
Signal_Up.setlineWeight(2);
Signal_Down.setPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_Down);
Signal_Down.setdefaultColor(color.Orange);
Signal_Down.setlineWeight(2);
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
alert(open>1.2,”High UP!”,alert.BAR,sound.DING);
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.
Hi REDK,
On the Alert_Bar_v1.txt the chartbubble covers up everything!
Is there a way to show the bubble on the bottom of the screen, showing only the last candle and the current candle, showing open price and close price, pluas a bubble showing the difference in price.
Your help is highly appreciated
Thanks
Joe