The Simple Moving Average (SMA) indicator is an arithmetic mean of security's price over a number of time periods. The fewer time periods are used, the more responsive the moving average to the price changes. SMA results as a smoothed line that makes it easier to identify the price trend.
SMA = (A1 + A2 ... + An) / n
where:
An – the price of an asset at period n
n – the number of total periods
SMA explained in under a minute
Want a simple visual explanation of the SMA indicator? Watch this short video to see how it works in action.

INPUTS
| Price |
|---|
The following data sources are available for the price:
|
| Input | Description |
|---|---|
| Length | The number of bars used to calculate SMA |
| Displace | The number of bars the indicator to be shifted to |
PLOTS
The plot renders the data you are working with on the chart. You can show/hide a plot by clicking the corresponding item in the settings. Every plot has a set of basic settings that you can change: color, weight, and type.
| Plot | Description |
|---|---|
| SMA | The Simple Moving Average plot |
| Color |
|---|
Click the color rectangle under the plot's name to open the palette. Use the slider at the bottom to set the opacity of the color. PaletteTo create a custom color:
The custom-created colors are added to your palette. To remove a custom color, drag it out of the palette. |
| Weight |
| Change the value (in px) to adjust the thickness of the plot. |
| Type |
The following plot types are available:
|
OVERLAYING
Check Overlaying to display the indicator on the chart. Otherwise, the indicator is shown in a study pane down below.

