EMA Trend Meter Indicator

EMA Trend Meter Indicator

EMA Trend Meter: An Essential Indicator for Trend Detection

Introduction

The “EMA Trend Meter” can be an interesting tool to identify the direction and strength of a financial asset’s trend. In this article, we will explain the indicator in detail, from its setup to its interpretation.

Fundamentals of the EMA Trend Meter

The “EMA Trend Meter” is based on the Exponential Moving Average (EMA), which is a more sensitive version of the moving average that gives more weight to recent data. This indicator uses four EMAs of different periods (1, 7, 14, and 21 days) to detect the direction of the trend and its strength. These periods, as well as the type of averages, are adjustable, as we will see now.

Setup and Parameters

The indicator consists of several adjustable parameters:

  • src: Defines the price source, usually the closing price.
  • p0, p1, p2, p3: Represent the periods of the EMAs, set at 1, 7, 14, and 21, respectively.
  • t0, t1, t2, t3: Types of moving averages, all initially set as exponential averages.
  • n: Period used for the calculation of the Rate of Change (ROC).
  • Additionally, parameters are incorporated to calculate the RSI and the Stochastic Oscillator, key elements to determine the strength of the trend.

Logic of the Indicator and Calculation

The EMAs are calculated on the selected price, adjusting the indicator’s sensitivity to price changes. The ROC of the EMAs offers a measure of the speed at which the trend changes. By combining the reading of the variation of the EMAs with that of the stochastic RSI, the “EMA Trend Meter” provides a comprehensive view of the direction and strength of trends.

Interpretation of the Indicator

The interpretation focuses on the color of the EMA lines and the relative position of the Stochastic K and D. EMAs that change to green indicate an uptrend, while red suggests a downtrend. A Stochastic K above D reinforces the buy signal, and vice versa for the sell signal.

Trading Alerts

The indicator generates buy alerts when more than one EMA turns green and the Stochastic K is above D. Similarly, sell alerts are generated under opposite conditions. This is a way of combining signals from different indicators.

Conclusion

The “EMA Trend Meter” can be a powerful tool for traders looking to capture and analyze market trends accurately. Its ability to combine multiple indicators on a single chart makes it indispensable for future trading strategies.

Indicator Code in ProBuilder

Below is the code for the indicator in the ProBuilder language, designed to be easily integrated into the ProRealTime platform:

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. groelandes • 218 days ago #

    Cuando te descargas el fichero itf, en su código no aparece toda la configuración de alertas ¿cómo puedo solucionar eso?

    • Iván • 216 days ago #

      Si lo descargas e importas en tu PRT verás que se han creado las variables para luego configurar el indicador. Estas variables son las líneas 8 a 21 del código.

  2. WhyAskOZ • 206 days ago #

    Hi, Ivan

    As always you are doing great coding. The code works on my PRT, however the issue i face is the colour of the lines particularly Stochastic lines which in your screenshot is Black & White. I use black background so i can’t see black line.

    I know all your code has pre-defined colours written inside but can we have colour selection menu ? similar to existing PRT indicator where we can select the colour by going into setting and then change to whatever we like?

    Nevertheless How do i change this black and white colour you applied in your code to green and red? and what line i need to change in the code?

    thanks

    • Iván • 206 days ago #

      You can delete in the last line (return) the configuration for color. Delete coloured(xx,xx,xx) and you will be able to configure after in a new window.
      You can also change color directly in code. Check lines after line 40.
      If you want change background color you can go to settings in the menu.

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar
Related users ' posts
Iván
2 weeks ago
Madrosat Bonjour ivan Quelle différence il y a t il entre Extra trend et ultra trend lequel est le p...
MaoRai54 dear Ivan, it seems to be very interesting but please clarify what are all the lines I see i...
Iván Hi! you have the answer in the last line of code... MacdMiddle as "histo" style(histogra...
kats Le Top , a utiliser avec le nuage violet et alerte TN pour plus de précision.
roccafragius Hello Ivan, very good job! May I ask you to translate teh script from TradingView named Tre...
Iván Hi! yes. You can ask for it here: https://www.prorealcode.com/free-code-conversion/
roccafragius Thank you so much Ivan! I created this request in english Translate from TradingView Indicat...
Regisnew très bel indicateur merci
Jean2139 Bonjour Yvan, Merci pour ton indicateur que je trouve très intéressant. Je suppose que tu ...
Suffi Hier eine kleine Korrektur: //-----Inputs-----------------------------------------// MALengt...
kats Bonjour, J'ai une question etes vous trader? Je m'explique , j'ai téléchargé tous les indi...
Faisalx Hola Ivan. Thanks for your great job. I would appreciate if you have look at my request http...
roccafragius Thank you for all these useful information!! Very great job Ivan! THank you so much
geroniman Merci Ivan, super travail. On peut toujours compter sur toi pour apporter des innovations su...
Stenozar Ciao mi restituisce errore line 1; forse è perchè utilizzo la versione 11 ? in questo caso d...
Stenozar Ciao IVAN , mi da errore per la riga 49 "print tema low"; puoi suggerirmi la modifica da met...
Iván Avete provato a scaricare il file .itf?
Iván Allora crei un nuovo post. Lo aspetterò.
Stenozar Ciao Ivan, ho inserito il post con la richiesta di traduzione. Se puoi vedere, grazie!
Iván perfect!
kats BONSOIR c bon merci j ai trouve ce weekend merci de votre reponse cdlt
the_giorgio Hi, nice work I would like to understand something about prorealtime code. With your ...
Iván Hello. When you use the drawcandle() instruction then in the configuration window you add ...
Gaspare Ciao Ivan si puo' inserire una strategia su questo indicatore per ottimizzare le variabil...
Bernard13 (Je réécris mon commentaire -français- en français car certains mots ne correspondaient pas ...
Iván 1000 indicateurs !!! brutaux
Lean Me parece muy buen indicador, y se complementa muy bien en mi sistema, ¿podrías crear un scr...
Iván Gracias! Para el screener sólo tienes que copiar el indicador y poner como condición de búsq...
Lean Muchas gracias Iván, ya lo he podido crear.
Doddge Hola Iván, ¿sería posible crear un screener que indique cuándo las velas coloreadas del indi...
RTR Ivan thank you for the pro-screener. I a trying to understand how to write the signals from ...
Iván Hi, Lines 62 and 63. These lines define buy and sell conditions.
Iván Hi You should delete from the indicator code all drawing functions and all variables not us...
Iván I've created a screener to show [longcondition or shortcondition]
Chrisinobi Hallo Ivan, Danke das ist Perfekt !! Kannst du bitte in der Screener-Bibliothek die itf. hoc...
MaoRai54 Thanks, now it's OK. in your first code at line 15-16 it's missing.
Madrosat Hello Ivan Did you try a strategy with this indicator
Iván Hi. No I didn't. This is a code translation requested by an user a few days ago.
Iván
9 months ago
cjr30 Simplemente modifica las lineas 19 y 21 por las siguientes: drawtext("▲",barindex,low-0.1*a...
groelandes Gracias!!
WhyAskOZ i copied the code into strategy and it gives error on line 21 and 23. it says " Line 1: ...
Iván
9 months ago
Madrosat Hello Ivan You have interesting topics on indicators , smart supertrend, optimised trend t...
Iván Hi! thanks. All of these codes are translations requested in the forum. I've on mind to back...
Raspete01 Buenos días Iván, estoy intentando llevar el código eliminando los colores y pasando un Back...
Iván
10 months ago
winnie37 Hi Ivan, if i want to use it, and call the oscillator value (in grey, green or red), how to...
Iván The oscillator is smoothtype. In inputs there is de lag to configure the output

Top