AtulGoswami

InsideBar2.0

AtulGoswami Aktualisiert   
Inside Bar: Inside Bar is defined as, " when candle body range falls within previous day candle body".
Some of us take the whole prices range . Here i have taken only the price range of the body of tehecandle.


I have created an indicator to identify Inside bras and draw target levels on both the sides. Traders can easily convert it into a strategy and checkout the success rate.


This script is written to identify InsideBar and then plot target 1 and target 2 irrespective the direction of following candles.


Inside Bar is here defined clearly when the whole body( Not high/Low, but Open and Close Only of the candle falls within the whole body of previous candle

Few static Variables are declared for one time use to store the following values


MotherCandle Index

High and Low of MotherCandle

Target 1 equal to size of the body of mother candle

Target 2 equal twice the size of Mother Candle


Depending upon the direction of the trend and breakout of the MotherCandle boundaries, target lines and labels are drawn.

Line.delete function is used to delete all the previous lines to keep the chart clean and not draw line on all every inside-bar detected in the past.


Label.delete function is used to delete all the previous labels for Target levels to clearly show current target levels.

barcolor() function is used to change the inside bar candle changed to "Yellow" .
Versionshinweise:
changing variable name, making it small and efficient

Founder-CEO - TogetherInvesting Club
942A, Spaze TechPark, Sohna Road, Gurgaon, 122001, India
Open-source Skript

Ganz im Spirit von TradingView hat der Autor dieses Skripts es als Open-Source veröffentlicht, damit Trader es besser verstehen und überprüfen können. Herzlichen Glückwunsch an den Autor! Sie können es kostenlos verwenden, aber die Wiederverwendung dieses Codes in einer Veröffentlichung unterliegt den Hausregeln. Sie können es als Favoriten auswählen, um es in einem Chart zu verwenden.

Haftungsausschluss

Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.

Möchten Sie dieses Skript auf einem Chart verwenden?