Skip to Main Content

JavaScript Indicator Examples

Coloring Candles

Coloring Candles

The following script colors blue all the candles which are above SMA(50...
Coloring Lines

Coloring Lines

The following script paints an SMA which is green if it's below the price action and red if it's above...
Drawing Rays

Drawing Rays

The following script paints a ray connecting last 2 of Fractal High points...
Painting Clouds

Painting Clouds

The following script paints an SMA-based color cloud which is green whenever a short SMA is above the long one and red ...
Painting Earnings on a Chart

Painting Earnings on a Chart

This script paints Earnings events over candles as bubbles. The bigger is the bubble, the bigger was the analyst ...
Painting Labels on Candles

Painting Labels on Candles

The following script paints the High price value over Fractal Highs. It also paints triangle icons for all the Fractal ...
Painting Earnings on a Chart

Painting Earnings on a Chart

This script paints pre-market range over the price action...
Using Additional Time Frame Data

Using Additional Time Frame Data

This indicator paints previous week close price as a line...
Using Alternative Data

Using Alternative Data

This indicator paints horizontal levels at strike prices. Each level's thickness depends on the amount of contracts ...
Using Script Input Parameters

Using Script Input Parameters

In many cases, it is beneficial to have input parameters for indicators, such as moving average (MA) length, multipliers...
Using Stacking on Histograms

Using Stacking on Histograms

This indicator paints the distance form SMA(20), SMA(50) and SMA(70) as a stacked histogram. Each distance is colored ...
Using time_of(), library(), function()

Using time_of(), library(), function()

This script paints Volume histogram with an "average volume for given time" line atop of it. This average volume is ...