Pin bar modified
Forums › ProRealTime forum Français › Support ProBuilder › Pin bar modified
- This topic has 4 replies, 4 voices, and was last updated 6 years ago by Alai-n.
Viewing 5 posts - 1 through 5 (of 5 total)
-
-
06/22/2018 at 9:05 AM #74008
Bonjour,
Je vous partage le code d’un indicateur trouvé ici meme, qui detecte automatiquement les “pin bar”
Cependant il les detecte toutes et j’aimerais un filtre à savoir, affiché le spin bar negative si : la bougie et rouge avec meche au dessus, positive si : bougie verte avec meche en dessous.
En gardant les memes conditions que ‘lindaciteur d’origine, merci de me venir en aide.
1234567891011121314151617value = 0clong1 = low < low[1] and low<low[2]clong2 = close >= low[1]-1 and open >= low[1]-1clong3 = abs(open - close) < 4*range/10clong4 = open > (low + range*5/10) and close > (low + range*5/10)cshort1 = high > high[1] and high > high[2]cshort2 = close <= high[1]+1 and open <= high[1]+1cshort3 = abs(open - close) < 4*range/10cshort4 = open < (high - range*5/10) and close < (high - range*5/10)if clong1 and clong2 and clong3 and clong4 thenvalue = 10elsif cshort1 and cshort2 and cshort3 and cshort4 thenvalue = -10endifreturn valuePs : désolé, je n’arrive pas le partager correctement ..
1 user thanked author for this post.
06/22/2018 at 10:17 AM #74038Comme ceci ? J’ai uniquement ajouté un test de la couleur de la bougie.
1234567891011121314151617value = 0clong1 = low < low[1] and low<low[2]clong2 = close >= low[1]-1 and open >= low[1]-1clong3 = abs(open - close) < 4*range/10clong4 = open > (low + range*5/10) and close > (low + range*5/10)cshort1 = high > high[1] and high > high[2]cshort2 = close <= high[1]+1 and open <= high[1]+1cshort3 = abs(open - close) < 4*range/10cshort4 = open < (high - range*5/10) and close < (high - range*5/10)if clong1 and clong2 and clong3 and clong4 and close>open thenvalue = 10elsif cshort1 and cshort2 and cshort3 and cshort4 and close<open thenvalue = -10endifreturn value06/22/2018 at 1:12 PM #7408106/24/2018 at 8:52 PM #74266just a little
Pinbar on Chart123456789101112131415161718192021222324252627282930313233clong1 = low < low[1] and low<low[2]clong2 = close >= low[1]-1 and open >= low[1]-1clong3 = abs(open - close) < 4*range/10clong4 = open > (low + range*5/10) and close > (low + range*5/10)cshort1 = high > high[1] and high > high[2]cshort2 = close <= high[1]+1 and open <= high[1]+1cshort3 = abs(open - close) < 4*range/10cshort4 = open < (high - range*5/10) and close < (high - range*5/10)// graphics on ChartrL = 255gL = 0bL = 0rS = 0gS = 0bS = 255PIP = 10*Pipsize ///ARROW DISTANCELIN = 3 //LENGTH OF SEGMENT OF SUPPORT OR RESISTENCERESISTENCE = 1*Pipsize //DISTANCE OF THE SEGMENT OF THE RESISTENCESUPPORT = 1*Pipsizeif clong1 and clong2 and clong3 and clong4 and close>open thenDRAWARROWDOWN(barindex,HIGH+PIP)coloured(rS,gS,bS)DRAWSEGMENT(barindex,HIGH+RESISTENCE,barindex-LIN, HIGH+RESISTENCE) coloured(rS,gS,bS)elsif cshort1 and cshort2 and cshort3 and cshort4 and close<open thenDRAWARROWUP(barindex,LOW-PIP)coloured(rL,gL,bL)DRAWSEGMENT(barindex,LOW-SUPPORT,barindex-LIN, LOW-SUPPORT )coloured(rL,gL,bL)endifreturn06/25/2018 at 4:01 PM #74328 -
AuthorPosts
Viewing 5 posts - 1 through 5 (of 5 total)