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

  1. bluetime6 • 24 days ago #

    Hello Doctrading.

     

    Can you ask you for something?

    Can you code a screener screen pop guns?

    And the screener change to use for a strategy with

    entry after long triggercandle + x-points,

    stop after x-percent of the trigger candle,

    takeprofit of x-percent (maybe with/like fibo-levels)

    ?

    kind regards?

    blue

avatar
Register or

Likes

avatar avatar avatar avatar
Related users ' posts
bjoern You are absolutely right, thank for your comment. Already working on an optimization while u...
bjoern Added a range filter for entering positions. Performance seems to be much better, even with ...
Nicolas Thanks!
Nicolas Any group of shares you like!
mal Hi Nicolas, whar for a broker do you use for Future-Tarading with pro real time?
Nicolas Prorealtime trading with interactive broker, more information follow this link: https://trad...
Sofitech What is the timeframe(s) you woul suggest to use for this method ?On Forex and/or on stock m...
Doctrading Hello, Higher timeframes are better. I suggest D1 or H4.Best regards,
Dagge99 Why are you the only one sharing unfinished strategys that doesn't perform well? To help us ...
Nicolas What are you calling a finished strategy? This one has been coded by a request on forums, si...
clanli Hi Nicolas Thanks for a fantistic piece of code. I tried the following with really good res...
Stenozar Hi Nicolas, does it work with DAX? which indicator you prefer to trade Dax? thanks a lot fo...
Riccardo Benedetti Thanks a lot nicolas for this indicator. good job. I love the great work done simple. Thanks...
Riccardo Benedetti ciao nicolas mi piacerebbe provare a fare un backest di una strategia con questo indicatore ...
Francesco78  Sorry I must add that it looks great only if we start the backtesting from 2008. Im not fa...
Nicolas You can't upload images here, sorry.
triss1965@gmail.com Hi, I dont understand, when I do the backtest I get only drawdown and a big loos? Have I mis...
gabri Thanks a lot Nicolas. I keep using the manuals from the help tag on the software but I guess...
gabri Nicolas, I added some lines to the indicator you translated. They reflect the setting that ...
Nicolas I try to keep the online documentation up to date, because I'd like to add more examples in ...
Nicolas Hi Ciccio, you made a great job here, warm thanks again for your sharing spirit! 
M-AURELE Bravo pour tout ce travail !!
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 ...
piarou Objet : PRC_QEMA | indicator Bonjour, Bizarrement : • les deux paramètres sont en remarqu...
Nicolas En effet, c'est le cas si on copie/colle le code. Ces 2 variables sont inscrites en externes...
Maxime Leleux Nice screener but the 2 candelsticks around the doji should be long sticks (red and green). ...
Nicolas
4 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...
Ernesto1 J'ai essayé avec deux différents I ,  a =  3 périodes et un 3 x 5 = 15 périodes.Ie comme si ...
Wilko Nicolas, anytime I have an idea, I just search for it on ProRealCode and usually you have do...
Nicolas Of course! please add a query in probuilder forum and we'll work together on this indicator ...
Nicolas
4 months ago
Nicolas Because of no data available at the start of calculations. Add this at line 15 : if barindex...
srajtri Hi Nicolas, thanks for your updates and am very new in trading would you guide me to back t...
Nicolas Please post any question on forums, thanks.
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...
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...
Jean-Pierre Poulain Hello, I am in version 10.3 but it does not work  

Top