Indicator · Pine Script v5 · On the chart

P-EMA21

by gocaman

P-EMA21 plots a 21-period exponential moving average and two smoothed moving averages, defaulting to lengths 21 and 55, on the price chart.

View on GitHub

GitHub stars3on the repository
Pine versionv5runs as is
Lines of code251
Settings40inputs
LicenceNone stated
Last update2 days ago28 Oct 2026

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
  2. 2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
  3. 3Paste over the templateCreate a new indicator, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart, then adjust the settings with the gear icon next to its name.

Source Code

The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.

Overview

P-EMA21 places long and short labels when the EMA crosses either smoothed average. Source, lengths, and a percentage threshold change the calculations. Separate inputs choose a BIST stock group or a custom symbol list, a scan timeframe, and the table position for a multi-symbol scan. It is an indicator only and does not define exits or position size.

Details

Published by

gocaman on GitHub

Draws

On the price chart

Markets

Stocks

Timeframes

Any timeframe

Risk Notes

No repainting, lookahead or stacked entries were found in its code or README. That says nothing about how well it works: test it first.

Settings

The inputs you can change from the gear icon on the chart. Defaults are the author's.

SettingTypeDefaultVariable
Sourcesourceclosesrc
Grup seçstring1grupSec
PERİYOTtimeframeper
Konum Ayarıint20loc
YÜZDELİK GİRfloat1.02yuzdelik2
Lengthint21ma18_len
Sourcesourceclosesrc18
Lengthint21len
Lengthint55len1
1symbolBIST:AKSAsb1
2symbolBIST:ALARKsb2
3symbolBIST:ARCLKsb3
Show all 40 settings
SettingTypeDefaultVariable
4symbolBIST:AYGAZsb4
5symbolBIST:BRSANsb5
6symbolBIST:CCOLAsb6
7symbolBIST:CIMSAsb7
8symbolBIST:DOASsb8
9symbolBIST:ENJSAsb9
10symbolBIST:FROTOsb10
11symbolBIST:INDESsb11
12symbolBIST:JANTSsb12
13symbolBIST:KCAERsb13
14symbolBIST:KCHOLsb14
15symbolBIST:MAVIsb15
16symbolBIST:MGROSsb16
17symbolBIST:OTKARsb17
18symbolBIST:PGSUSsb18
19symbolBIST:SAHOLsb19
20symbolBIST:TAVHLsb20
21symbolBIST:THYAOsb21
22symbolBIST:TOASOsb22
23symbolBIST:TTRAKsb23
24symbolBIST:TUPRSsb24
25symbolBIST:SISEsb25
26symbolBIST:CWENEsb26
27symbolBIST:ASTORsb27
28symbolBIST:BINHOsb28
29symbolBIST:AKBNKsb29
30symbolBIST:VAKKOsb30
31symbolBIST:BIMASsb31
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.

Similar Pine Scripts

This overlay indicator plots a Supertrend from an ATR length and factor, four exponential moving averages, and a selectable VWAP or TWAP taken from a chosen timeframe on the price chart. It also shows MACD and stochastic with adjustable lengths, smoothing, ver

Indicator v5 Oscillators & momentumMoving averages
Updated 1 year ago · MPL-2.0 GitHub repository of Momentum Setup: Vijay Thakare Option Buying Scalping Setup
257 stars

This indicator plots a 200-period weighted moving average (WMA) on the main chart and monitors price deviations across multiple timeframes. It retrieves daily, 15-minute, 5-minute, and 2-minute price data to track distance from the 200 WMA relative to key sess

Indicator v5 Moving averagesSessions & time Repaints
Updated 7 weeks ago · None stated GitHub repository of Donald SPX - Options Trading
228 stars

TradersPost Trading Checklist is an overlay indicator that evaluates a suite of popular technical conditions for long and short trade setups. It checks session-anchored VWAP, fast and slow EMA alignments and crosses, 200 SMA, RSI overbought or oversold conditi

Indicator v6 Screeners & dashboardsTrend
Updated 3 months ago · None stated GitHub repository of TradersPost Trading Checklist

8zz反指標v2

by hansai-art
121 stars

The 8zz Contrarian Indicator plots reverse sentiment trading signals directly on the price chart based on tracked retail post activity. It generates bullish signals during retail panic and bearish signals during market euphoria. The indicator features adjustab

Indicator v6 Moving averagesOscillators & momentum
Updated 3 months ago · None stated GitHub repository of 8zz反指標v2
92 stars

This indicator plots five moving averages of a chosen source on the price chart, defaulting to EMA lengths 10, 20, 30, 40 and 50. The user can switch the average type to SMA, WMA or HMA and recolor each line. Wide translucent glows sit under the lines, and sof

Indicator v5 TrendMoving averages
Updated 2 months ago · Custom licence GitHub repository of Moon Dev Rainbow MA Ribbon 10-50

Price vs MA

by be-thomas
65 stars

This indicator builds a table of simple moving averages and places it on the price chart. It calculates a user-chosen number of SMAs whose periods start at a base length and increase by a fixed step. On the last bar it lists each period and its SMA value, colo

Indicator v4 Moving averagesScreeners & dashboards
Updated 6 days ago · GPL-3.0 GitHub repository of Price vs MA

More Moving averages scripts

Related on ForexR

Trade Your Charts With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers