EMA5 – TMA8 trading signals

EMA5 – TMA8 trading signals

Hi all,

Here is a simple code asked by one of my website user.

We have a BUY signal (green) if :

  • the exponential average 5 (close) > the triangular average 8 (close)
  • close > triangular average 8 but close of the previous candle < triangular average 8

Of course, we have a SELL signal (red) for the inverted conditions.

Don’t forget to set “achat” and “vente” to Histogram, and to set the colors.

I also added a blue line with value “0”.

The EMA5 is in red, the TMA8 is in blue.

Share this

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?

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

  1. gianlox • 08/23/2016 #

    I added a simple momentum indicator (MACD). I think much better results:
     
    achat = 0vente = 0MACD12M = MACDline[12,26,9](close)MACD12S = ExponentialAverage[9](MACD12M)
    // INDICATEURSEMA5 = ExponentialAverage[5](close)TMA8 = TriangularAverage[8](close)
    // ACHATca1 = close[1] < TMA8 and close > TMA8ca2 = EMA5 > TMA8
    IF ca1 and ca2 AND MACD12M>MACD12S AND MACD12M[1]>MACD12S[1] THENachat = 1ENDIF
    // VENTEcv1 = close[1] > TMA8 and close < TMA8cv2 = EMA5 < TMA8
    IF cv1 and cv2 AND MACD12M<MACD12S AND MACD12M[1]<MACD12S[1] THENvente = -1ENDIF
    return achat as “ACHAT”, vente as “VENTE”
     
    happy New Year !!!

  2. gianlox • 08/23/2016 #

    achat = 0
    vente = 0
    MACD12M = MACDline[12,26,9](close)
    MACD12S = ExponentialAverage[9](MACD12M)

    // INDICATEURS
    EMA5 = ExponentialAverage[5](close)
    TMA8 = TriangularAverage[8](close)

    // ACHAT
    ca1 = close[1] < TMA8 and close > TMA8
    ca2 = EMA5 > TMA8
    ca3 = MACD12M>MACD12S AND MACD12M[1]>MACD12S[1]

    IF ca1 and ca2 AND ca3 THEN
    achat = 1
    ENDIF

    // VENTE
    cv1 = close[1] > TMA8 and close < TMA8
    cv2 = EMA5 < TMA8
    cv3 = MACD12M<MACD12S AND MACD12M[1]<MACD12S[1]
    IF cv1 and cv2 AND cv3 THEN
    vente = -1
    ENDIF

    return achat as \"ACHAT\", vente as \"VENTE\"

     

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar avatar avatar
Related users ' posts
Appsoluxions Hi Nicolas, do you have the MT4 version of the indicator? I am not sure if these kind of que...
Nicolas Hi, don't have one sorry. But you can still ask for private coding through our programming s...
Appsoluxions Cool. Thanks for the response.
rama I want to use this indicator in trading system, it says zig zag is obsolete and not supported
Nicolas Right, due to its repainting behavior, the zigzag is not allowed in automated trading with r...
rama I noticed it changes as time progress, I am 7 as the average, how many period it wont chang...
Gordon101 Hi when I added your Guppy indicator to my chart it went below the chart beside the oscilla...
Nicolas Add it on the price by using the wrench located on the left upper side of your price chart.
Gordon101 Thanks Nicolas, worked a treat.
Rafa And the PriceMAPeriod? aren´t the same?
Nicolas The PriceMAPeriod is the period to make the average of all the last X medianprice found.
Rafa Thanks a lot Nicolás. Have a nice day
ak5hay2 Works like crazy on bitcoin. Use different timeframes. Thanks a lot Doc!!!
richyowen Hi, great code thanks. Very new to this forum. Is there a way to add a 100point target on an...
lisamitch50 Morning all, Just backtested on quite a few instruments, worked well on backtesting, but tel...
swapping merci gabri, on va le mettre à l'essai ;)
crolakstrading Hi Nicolas.. I'm really big fan of this indicator! is there any possibility to make this ind...
Nicolas Yes, that's possible. Please open a new topic in the forum.
crolakstrading Just saw your reply thank you!! I will open up a new topic!!
Leo Hi all, I posted a new version of this indicator ( I just add arrows to spot the local maxi...
Trading_En_El_Ibex35 Muchas Gracias por compartir este interesante indicador. Un saludo
xavieralava hola gracias leo
Khaled Thanks, but if I may ask what's EMA Period? The price which reverses the EMA[20] is not the ...
Francesco78 EMA is not a moving average, it is just the name we called the quantity defined above
Khaled My bad. Thank you so much!
rejo007 hello david, i'll try it could you tell me wich strategy do you use in real? thanks
David Somogyi Hello, I have a couple of DAX strategies of breakout and mean reversion. I'll try to post...
Roberto Blázquez Hi David, I just saw your strategy and it's good!!! I'm going to try it from today in real a...
Thomas007 Is there any way to build something similar for FX? I wonder what would be the replacement f...
Kris75 Hi Bolsatrilera, I love this indicator! Thanks; => did you develop a strategy around...
KarlBenjamin This "indicator" alone has completely changed my algorithms for the better! Id even go as fa...
ashee CAN YOU SHARE MT4 FILE
coyP Big thanks ! Can you explain me how can I put this ON my graph and not under the graph please ?
Wing There's a few threads on the forum about backtest and live trades being different at times. ...
ET I agree with verdi55. As it is now, the code will only test for a breakout on the upside (li...
Philipjonasson are u still active Wing?
Nicolas We do not offer free assistance for TOS. However, you can send demand for private paid codin...
phanz Hi community. May I know how you use this indicator please? Is it on the zero cross over? ...
sydney43025 Hello, I'm digging up this topic because I uploaded the code on a PRT v11.1 but the indicato...
David Balance thanks for sharing this excellent indicator.  Here are some thoughts.  please ad...
supertiti Il manque 2 slash devant len dans le code dur car la variable ne marche pas bonne journée
bearbull As per PhilipSchultz question above, has anybody managed to add code for when it turns blue,...
Ybr35 Bonjour Nicolas, lorsque je lance l'indicateur, il m'est indiqué que je dois définir les var...
Nicolas L'idéal est de télécharger le fichier itf joint sur cette page et de l'importer dans la plat...

Top