April 27


How to Transform any Indicator in Histogram

By Luca Valente

April 27, 2020


In this EasyLanguage Tutorial, we show you how to use the TradeStation Histogram visual mode. Many traders don't like to have the chart flooded with lines, drawings, and indicators.
They prefer to see the naked price. Let's take a simple example of a Moving Average from this link.
This moving average has an active slope function that indicates whether the direction is increasing or decreasing. Obviously, only this information can be viewed through a histogram. However, this information is very useful when we need a trend filter.

Let's Start to transform a Moving Average into a TradeStation histogram.

First of all, we modify the Tradestation EasyLanguage code in this way:



MA=average(Close, MA_length);

If MA>MA[1] and MA[1]>MA[2] then


If MA<MA[1] and MA[1]<MA[2] then


Plot1( MA_histo, “MA”,color,0,3 );

The TradeStation Indicator continues to calculate the moving average but the command Plot1 instead of drawing the line with the value of the average price will draw the fixed amount "1".

This happens because with this indicator we are interested only in seeing the color that changes when the average is descending or ascending (red and green).

 Some indicator settings must also be changed in Tradestation:

Now you have only the TradeStation Histogram in your chart. The green-red histogram TradeStation can be used to display a large number of indicators.

We can also create another histogram that shows us when prices are below or above the moving average.

Also in this case with a red and green histogram, we will have the red color when the prices will be below the moving average while the green color will be above.



MA = average(Close, MA_length);

If Close>MA

If Close<MA then

Plot1( MA_histo, “MA”,color,0,3 );

Do you want to learn EasyLanguage & PowerLanguage for TradeStation and MultiCharts?

 Start here:

Luca Valente

About the author

Finance Strategy System was created to share what I have learned in the last 11 years in the market.

In this blog, I talk about finance, trading, trading platforms, strategies, indicators, automated trading systems, and programming.

You can find dozens of free tutorials and many technical indicators to download for free.

I'm not a native English speaker, so be patient with my English.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Learn To Code & Build Strategies
Using EasyLanguage.