Trend Lord Indicator

Trend Lord Indicator

The Trend Lord indicator is a visual tool that enables traders to identify trends more intuitively by using custom candles. Unlike traditional candles, this indicator colors the candles according to the trend direction, making it easier to spot shifts or consolidation in price movements.

This article will guide you through the setup of the Trend Lord indicator and show you how to adjust its parameters to optimize it for your analysis needs. At the end, you’ll find the code required to implement it in ProRealTime.

1. Parameter Calculation and Configuration

The Trend Lord indicator structure includes several key parameters that control the behavior and visualization of the candles on the chart. These parameters affect aspects like the moving average calculation period and the smoothing method.

a) Moving Average Period (maperiod)

The maperiod parameter defines the number of bars used to calculate the moving average. This value determines the indicator’s sensitivity to price changes. A lower maperiod will make the indicator respond faster to price movements, while a higher value will reduce noise and highlight stronger trends only. This value is set to always be at least 1 in the code to avoid calculation errors.

b) Smoothed Moving Average (smoothedSMA)

The smoothedSMA parameter allows the use of a smoothed simple moving average. Enabling this option results in a smoother candle transition, which visually reduces volatility in the indicator. This is especially useful for those who prefer a cleaner look and like to identify trends with less abrupt movements.

c) Moving Average Method (mamethod)

This parameter defines the calculation method of the moving average applied in the indicator. Changing the mamethod allows trying different approaches and choosing the one that suits the market or asset being analyzed. ProRealTime offers various options for calculating moving averages, including simple and exponential, which can be applied in the code.

2. Defining Custom Candles in the Trend Lord

The Trend Lord indicator uses a unique approach to define its own “candles” based on average open, high, low, and close values, calculated according to the moving average and other parameters:

  • bufopen: Determines the open price of each candle. It is calculated accumulatively using the src value (which refers to the custom close).
  • bufhigh: Represents the candle’s high price, equal to the bufopen value.
  • buflow: Calculates the low price of each candle, smoothed using the SqLength value, which is the square root of maperiod.
  • bufclose: Represents the close of each candle, set equal to the buflow value.

This custom calculation of the candles allows an alternative visualization of prices, where each candle behaves more fluidly than a traditional price candle.

3. Candle Colors According to Trend

A primary feature of the Trend Lord indicator is its color-coding of candles based on the trend direction:

  • Green candles: Displayed when the open price (bufopen) is higher than the close price (bufclose). This indicates a potential bullish trend.
  • Red candles: Displayed when the close price is higher than the open, suggesting a bearish trend.

This color-coding allows a quick visual interpretation of the trend, making it easy to identify the direction and potential changes. The candle color is a simple yet powerful representation, helping traders focus on the general price movement.

4. Implementing the Code in ProRealTime

Below is the code necessary to implement the Trend Lord indicator in ProRealTime. This code is written in the ProBuilder language, which is specific to the ProRealTime platform.

This code defines the visual characteristics of the indicator. Each custom candle is calculated based on the type of moving average and smoothing method selected by the user. By changing the parameters maperiod, smoothedSMA, and mamethod, the user can adapt the indicator to their specific needs, adjusting the sensitivity and smoothness of the candles.

5. Conclusion and Usage Tips

The Trend Lord indicator is a valuable visual tool for detecting trends in financial markets. By employing a custom candle representation, it facilitates the identification of trend reversals and enables a focus on the general direction of price movements.

Usage Tips:

  • Adjust maperiod based on the timeframe: If trading on short-term charts, consider reducing the period to capture quick changes. On long-term charts, a higher maperiod can help identify predominant trends.
  • Try different moving average methods: Changing mamethod allows experimenting with different calculation styles, which can provide alternative trend perspectives.
  • Use smoothed candles: Enabling smoothedSMA can reduce visual volatility, ideal for those who prefer stable and easy-to-interpret charts.

This indicator is especially useful in trending markets and less effective in sideways ranges, where color changes might occur frequently without indicating a clear trend. Like any other indicator, Trend Lord should be used as a complement to other technical analysis tools for more accurate results.

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

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar
Related users ' posts
Vonasi Discussion on this indicator/filter can be found here: https://www.prorealcode.com/topic/121...
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.
Domenec Claro Juanjo de todas maneras en deinversoratrader.com tienes estsos osciladores evolucionad...
Dron Hola Domenec, en la descripción hablas del indicador velas de colores, no lo encuentro en la...
Domenec Hola Dron mira en el blog deinversoratrader.com en formacion indicadores ahi hay varios grat...
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.
Geronima Ortiz I watched the video three times, but I can not put the npips parameter as a variable. I do...
Geronima Ortiz I think the video is for an old version of prorealtime, the images do not correspond at all ...
Nicolas indicator1 = CALL “PRC_StopReversal”[npips, 1] and define npips in the optimization window ...
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
Caribeengeek Bonjour j’avais vu que vous proposiez d’écrire des codes pour ceux qui s’y connaisse pas Mai...
Caribeengeek Les devises unité
Nicolas Merci d'utiliser le forum pour les demandes de programmation personnalisée
ullle73 nicolas, can you somehome make this to be in the background of the price chart?
jonpt88 none did that yet right?
Nicolas You can ask for a code modification on forums, please open a new topic with your request.
Toto le Heros Thanks Nicolas. I read somewhere that in the calculation, we should round the value of the A...
Nicolas aADX = round(adx[10])
bolsatrilera
7 years ago
Rainbow Oscillator
Rainbow Oscillator
1
Indicators
Maxime Baudin Interesting, thanks! Combine this indicator with the bollinger bands there is enough to make...
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...
supertiti Bonsoir à tous For those who like me want to calibrate this indicator on a scale of 0 to ...
verdi55 You can find me at www.FXautomate.com Ahh. So i got it ? 4 different supertrends without th...
juanj What? This has nothing to do with the website. The site is simply a service to help people ...
Nicolas Advertising is allowed,as long as people are helping others and if provided services are abo...
styrke Hello Nicolas, Nice screener, I appreciate the way you always try to condense at maximum th...
Nicolas There's no particular reason. RSI is widely use with its default period and results seems re...
Vonasi I noticed a couple of typo errors in the code. The list of variables lines 4 to 11 should be...
Genotik Thank you for your important contribution this week which is much appreciated! Happy New Yea...
Vonasi No problem. I hope they are useful to someone. Happy and hopefully prosperous New Year to y...
DarioMazza Hi Vonasi, i have a question for you, the comand "pricetype" where did you found it in the ...
Vonasi PriceType is just a variable that I use. The value decides what type of price is used in the...
Vonasi I noticed a couple of typo errors in the code. The list of variables lines 4 to 11 should be...
swapping merci gabri, on va le mettre à l'essai ;)
Nicolas
7 years ago
Trinity Impulse
Trinity Impulse
5
Indicators
ribou ah d'accord merci beaucoup
domenico nlevel1 non modifica la curva al variare del suo valore
tiger_man_no1 Very nice ; what is the best period input date for DAILY CHART ?

Top