Indicator “Candle & TMA8 open”

Indicator “Candle & TMA8 open”
Hi all, Here is an indicator coded for one of the readers of my website. We BUY if :
  • bullish candle (close > open)
  • close and open > triangular moving average 8, applied to open
  • lowest of the candle < TMA8 with at least 1 pip below the TMA8
  • size of the inferior shadow  > size of the body
  • size of the upper shadow <= 2 pips
  • no doji : size of the body >= 3 pips
Of course, we SELL for opposite conditions. So here is the code :
achat = 0
vente = 0

TMA8 = TriangularAverage[8](open)

// CONDITIONS D'ACHAT
ca1 = close > TMA8 and open > TMA8 and close > open
ca2 = low < TMA8
ca3 = (open - low) > (close - open)
ca4 = high - close <= 2 * pipsize
ca5 = close - open >= 3 * pipsize

// CONDITIONS DE VENTE
cv1 = close < TMA8 and open < TMA8 and close < open
cv2 = high > TMA8
cv3 = (high - open) > (open - close)
cv4 = close - low <= 2 * pipsize
cv5 = open - close >= 3 * pipsize

IF ca1 and ca2 and ca3 and ca4 and ca5 THEN
achat = 1
ELSIF cv1 and cv2 and cv3 and cv4 and cv5 THEN
vente = -1
ENDIF

return achat as "ACHAT", vente as "VENTE"
Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

New! PRC is also now on YouTube, subscribe to our channel for exclusive content and tutorials

avatar
Register or

Likes

avatar avatar
Related users ' posts
Ernesto1 Good Job !!! Ciccio
ALE great! :-)
Sofitech Ce code n'est valable que sur la V10.3 ? sur le 10.2 il y a une erreur de syntaxe dans le fi...
Nicolas Oui en effet, c'est un indicateur "10.3" à cause uniquement de la mise en forme des courbes ...
Maxime Leleux Nice screener but the 2 candelsticks around the doji should be long sticks (red and green). ...
Nicolas
2 months ago
Holt EMA
Holt EMA
0
Indicators
David Nicolas I've looked at it again and there's a problem.  As an example here's a simple cross...
Nicolas You'll need to preload bars to get the good calculations of you indicators. I did not test i...
David Nicolas I tried DEFPARAM Preloadbars = 5000 And still the same drawn output of entries/exit...
supertiti Voici un code de VIDYA construit par Sohocool : // MOYENNE EXPONENTIELLE ADAPTIVE VIDYA by ...
Matriciel Merci Supertiti. Je trouve que ce code est difficile à règler et n'est pas d'une grande pré...
Ernesto1 J'ai essayé avec deux différents I ,  a =  3 périodes et un 3 x 5 = 15 périodes.Ie comme si ...
Nicolas
3 months ago
SoloContado Hello Nicolas,   thanks a lot for your many contributions in this post. I have a prob...
Nicolas Because of no data available at the start of calculations. Add this at line 15 : if barindex...
luigi Ciao Nicolas. Approfitto di questo spazio per chiederti se puoi aiutarmi. Avrei bisogno di u...
Nicolas Si prega di utilizzare i forum per chiedere richieste di codice per favore.
Wilko Hi Nicolas!, Thanks for providing code for the FRAMA! If I have understood correctly, one s...
Nicolas This indicator is only compatible with Prorealtime 10.3
kajsy88 I'm using prorealtime suplied by ig markets so that's potentially why then !
davidspain It would be possible to use this screener at the same time than the recent one about high vo...
triss1965@gmail.com HELP, WHY DONT I NOT GOT THE INDICATOR IN CHART. JUST UNDER?????????????
Nicolas Use the wrench on the upper left side of your price chart to add correctly indicator on PRICE.
gianlox I added a simple momentum indicator (MACD). I think much better results:   achat = 0v...
gianlox achat = 0 vente = 0 MACD12M = MACDline[12,26,9](close) MACD12S = ExponentialAverage[9](MA...
Somatolysis   Hi IGOSNELL, you´ll find other of my strategies here - but without the code - maybe...
IGOSNELL Thanks but unfortunately can't read German. If you can show that your strategies can work on...
Nicolas Thank you for contribution. Please consider that advertising is tolerate as long as you cont...
finplus Bonjour, j'ai retesté hier sur la paire AUD/USD timeframe 1 heure sur mon compte réel chez I...
finplus Bonsoir, j'ai de nouveau aujourd'hui lancé la stratégie en réel sur mon compte IG sur la pai...
AleX 0 improvments, I tried a lot of modified version but no one was working. I think that only w...
Nicolas Ok Doc, beware of intraday, it's a battlefield full of random noises :) Maybe we can work to...
phili711 Bonjour Si la moyenne 100 est au dessus de la moyenne 20 le trend est baissier zlors pourqu...
Nicolas La comparaison se fait entre la valeur de la moyenne actuelle et telle qu'elle était il y a ...
Nicolas You have certainly apply the indicator twice on the price chart. If you want to hide one of ...
fabriziomerlo Buongiorno Nicolas,  come faccio a trasformare questo interessantissimo indicatore in uno s...
Nicolas Si desidera testare una croce sopra di 2 media mobile? Si prega di fare un argomento nel for...

Top