Indicator · Pine Script v6 · Own pane

Saham: Papan Gerak By. Akhmfz

by akhmfz

Papan Gerak is a multi-dimension technical analysis dashboard aimed at Indonesian stocks.

View on GitHub

GitHub stars1on the repository
Pine versionv6current
Lines of code285
Settings40inputs
LicenceMIT
Last update3 months ago8 Jul 2026

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above, or the copy button on the code below.
  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

285 lines of Pine Script v6 from src/modules/01-base.pine, published under MIT. Keep the author's credit and licence lines when you reuse it.

01-base.pine
// @version=6
// 01-base.pine — Papan Gerak: Header, Inputs, Tema, Utilities
// ==========================================================
// Papan Gerak — Technical Analysis Dashboard
// Author : Muhammad Akhmal (AKHMFZ)
// Contact: akhmfz.analytics@gmail.com
// License: MIT
// Built   : Pine Script v6 for TradingView
// ==========================================================

// --- Indicator Definition ---
indicator(
    "Saham: Papan Gerak By. Akhmfz",
    shorttitle = "P.Gerak",
    overlay = false,
    format = format.price,
    precision = 0
)

// ==========================================================
// 1. SETTINGS — General
// ==========================================================
// --- Display ---
tablePositionInput = input.string(
    "Top Right",
    "Table Position",
    options = ["Top Left", "Top Right", "Bottom Left", "Bottom Right"],
    display = display.data_window
)
fontSizeInput = input.int(1, "Font Size", minval = 1, maxval = 3, display = display.data_window)
modeInput = input.string("Standard", "Mode", options = ["Compact", "Standard", "Detailed"], display = display.data_window)
bahasaInput = input.string("Indonesia", "Bahasa", options = ["Indonesia", "English"], display = display.data_window)
colorThemeInput = input.string("Gelap", "Color Theme", options = ["Gelap", "Terang", "Bursa Hijau", "Biru Nusantara", "Emas Premium"], display = display.data_window)

// ==========================================================
// 2. SETTINGS — Trend Parameters
// ==========================================================
emaFastPeriod = input.int(20, "EMA Fast Period", group = "Trend", display = display.data_window)
emaMidPeriod = input.int(50, "EMA Mid Period", group = "Trend", display = display.data_window)
emaSlowPeriod = input.int(200, "EMA Slow Period", group = "Trend", display = display.data_window)
superTrendFactor = input.float(3.0, "SuperTrend Factor", step = 0.1, group = "Trend", display = display.data_window)
superTrendPeriod = input.int(10, "SuperTrend ATR Period", group = "Trend", display = display.data_window)
adxLength = input.int(14, "ADX Length", group = "Trend", display = display.data_window)
adxThreshold = input.int(25, "ADX Threshold", group = "Trend", display = display.data_window)

// ==========================================================
// 3. SETTINGS — Momentum Parameters
// ==========================================================
rsiLength = input.int(14, "RSI Length", group = "Momentum", display = display.data_window)
rsiOb = input.int(70, "RSI Overbought", group = "Momentum", display = display.data_window)
rsiOs = input.int(30, "RSI Oversold", group = "Momentum", display = display.data_window)
macdFast = input.int(12, "MACD Fast", group = "Momentum", display = display.data_window)
macdSlow = input.int(26, "MACD Slow", group = "Momentum", display = display.data_window)
macdSignal = input.int(9, "MACD Signal", group = "Momentum", display = display.data_window)
stochK = input.int(14, "Stochastic K", group = "Momentum", display = display.data_window)
stochD = input.int(3, "Stochastic D", group = "Momentum", display = display.data_window)
stochOb = input.int(80, "Stoch Overbought", group = "Momentum", display = display.data_window)
stochOs = input.int(20, "Stoch Oversold", group = "Momentum", display = display.data_window)

// ==========================================================
// 4. SETTINGS — Volatility Parameters
// ==========================================================
atrLength = input.int(14, "ATR Length", group = "Volatility", display = display.data_window)
bbLength = input.int(20, "Bollinger Length", group = "Volatility", display = display.data_window)
bbMult = input.float(2.0, "Bollinger Multiplier", step = 0.1, group = "Volatility", display = display.data_window)
chopLength = input.int(14, "Choppiness Length", group = "Volatility", display = display.data_window)

// ==========================================================
// 5. SETTINGS — Volume Parameters
// ==========================================================
volMaLength = input.int(20, "Volume MA Length", group = "Volume", display = display.data_window)
volSpikeMult = input.float(2.0, "Volume Spike Multiplier", step = 0.1, group = "Volume", display = display.data_window)

// ==========================================================
// 6. SETTINGS — Scoring Weights
// ==========================================================
weightTrend = input.int(30, "Trend Weight (%)", minval = 0, maxval = 100, step = 5, group = "Weights", display = display.data_window)
weightMomentum = input.int(30, "Momentum Weight (%)", minval = 0, maxval = 100, step = 5, group = "Weights", display = display.data_window)
weightVolatility = input.int(20, "Volatility Weight (%)", minval = 0, maxval = 100, step = 5, group = "Weights", display = display.data_window)
weightVolume = input.int(20, "Volume Weight (%)", minval = 0, maxval = 100, step = 5, group = "Weights", display = display.data_window)

// ==========================================================
// 7. SETTINGS — Smart Money (Optional)
// ==========================================================
enableSmartMoney = input.bool(false, "Enable Smart Money Flow", group = "Smart Money", display = display.data_window)
weightSmartMoney = input.int(20, "SM Weight (%)", minval = 0, maxval = 100, step = 5, group = "Smart Money", display = display.data_window)
smVolumeThreshold = input.float(2.5, "SM Volume Z-Threshold", step = 0.1, group = "Smart Money", display = display.data_window)
smPeriod = input.int(20, "SM Lookback Period", group = "Smart Money", display = display.data_window)

// ==========================================================
// 8. SETTINGS — Signal Parameters
// ==========================================================
minSignalBars = input.int(5, "Min Bars Between Signals", minval = 1, maxval = 50, group = "Signal", display = display.data_window, tooltip = "Jarak minimal antar sinyal (dalam bar). Mencegah sinyal beruntun terlalu rapat.")
signalFilterMode = input.string("Disabled", "Signal Filter", options = ["Disabled", "Only Trending (Chop<38)", "Only Ranging (Chop>62)"], group = "Signal", display = display.data_window, tooltip = "Hanya izinkan sinyal saat market trending (Chop<38) atau ranging (Chop>62). Nonaktifkan untuk semua kondisi.")
confirmOnBarClose = input.bool(true, "Confirm on Bar Close", group = "Signal", display = display.data_window, tooltip = "Hanya kirim alert saat candle benar-benar tutup. Mencegah sinyal/alert palsu di tengah bar berjalan (repaint). Nonaktifkan untuk respons real-time lebih cepat.")

// ==========================================================
// 9. SETTINGS — Risk Management
// ==========================================================
showRiskLevels = input.bool(true, "Show Risk Levels", group = "Risk Mgmt", display = display.data_window, tooltip = "Tampilkan baris Level Referensi (SL/Target) di tabel. Nonaktifkan untuk mode scan cepat.")
slTypeInput = input.string("ATR", "SL Type", options = ["ATR", "Swing Low/High", "Both (Wider)"], group = "Risk Mgmt", display = display.data_window, tooltip = "Metode Stop Loss: ATR-based, Swing Low/High, atau kombinasi (ambil yang lebih jauh).")
slAtrMult = input.float(1.5, "SL ATR Multiplier", minval = 0.5, maxval = 5.0, step = 0.1, group = "Risk Mgmt", display = display.data_window, tooltip = "Pengali ATR untuk SL. Semakin besar semakin longgar. Contoh: 1.5 × ATR(14).")
slSwingPeriod = input.int(10, "SL Swing Lookback", minval = 5, maxval = 50, group = "Risk Mgmt", display = display.data_window, tooltip = "Jumlah bar untuk mencari swing low/high sebagai referensi SL. Makin panjang makin jauh dari entry.")
targetR = input.float(2.0, "Target R-Multiple", minval = 0.5, maxval = 10.0, step = 0.5, group = "Risk Mgmt", display = display.data_window, tooltip = "Target take-profit sebagai kelipatan risiko. 2R = profit 2× dari jarak SL.")

// ==========================================================
// 10. SETTINGS — Position Sizing
// ==========================================================
showPositionSizing = input.bool(false, "Show Position Sizing", group = "Position Size", display = display.data_window, tooltip = "Tampilkan kalkulator ukuran posisi (dalam lot) berdasarkan balance dan risk %.")
accountBalanceInput = input.int(50000000, "Account Balance (Rp)", minval = 1000000, step = 1000000, group = "Position Size", display = display.data_window, tooltip = "Total modal trading dalam Rupiah. Digunakan untuk menghitung jumlah lot per sinyal.")
riskPctInput = input.float(1.0, "Risk Per Trade (%)", minval = 0.1, maxval = 5.0, step = 0.1, group = "Position Size", display = display.data_window, tooltip = "Persentase modal yang siap dirisikokan per trade. Contoh: 1% dari Rp50jt = Rp500rb.")

// ==========================================================
// 11. SETTINGS — Multi-Timeframe Alignment
// ==========================================================
enableMTF = input.bool(true, "Enable MTF Alignment", group = "MTF", display = display.data_window, tooltip = "Aktifkan Multi-Timeframe Alignment Score. Menghitung alignment 3 timeframe untuk konfirmasi sinyal.")
mtfPrimaryTF = input.string("D", "Primary TF", options = ["D", "W", "M"], group = "MTF", display = display.data_window, tooltip = "Primary timeframe — entry timing. Default: Daily.")
mtfSecondaryTF = input.string("W", "Secondary TF", options = ["D", "W", "M"], group = "MTF", display = display.data_window, tooltip = "Secondary timeframe — trend konfirmasi. Default: Weekly.")
mtfTertiaryTF = input.string("M", "Tertiary TF", options = ["D", "W", "M"], group = "MTF", display = display.data_window, tooltip = "Tertiary timeframe — konteks makro. Default: Monthly.")
mtfPrimaryWeight = input.float(0.50, "Primary Weight", minval = 0.0, maxval = 1.0, step = 0.05, group = "MTF", display = display.data_window, tooltip = "Bobot primary timeframe dalam skor akhir. Default: 0.50 (50%).")
mtfSecondaryWeight = input.float(0.35, "Secondary Weight", minval = 0.0, maxval = 1.0, step = 0.05, group = "MTF", display = display.data_window, tooltip = "Bobot secondary timeframe. Default: 0.35 (35%).")
mtfTertiaryWeight = input.float(0.15, "Tertiary Weight", minval = 0.0, maxval = 1.0, step = 0.05, group = "MTF", display = display.data_window, tooltip = "Bobot tertiary timeframe. Default: 0.15 (15%).")
mtfAlpha = input.float(0.70, "Directional Alpha", minval = 0.0, maxval = 1.0, step = 0.05, group = "MTF", display = display.data_window, tooltip = "Bobot directional components (Trend+Momentum) vs context (Volatility+Volume). Default: 0.70.")
mtfMaxPenalty = input.float(0.25, "Max Conflict Penalty", minval = 0.0, maxval = 0.50, step = 0.05, group = "MTF", display = display.data_window, tooltip = "Penalti maksimum saat timeframe saling bertentangan. 0 = tanpa penalti, 0.25 = 25% maks.")
mtfDirectionHysteresis = input.float(10.0, "Direction Hysteresis", minval = 0.0, maxval = 30.0, step = 1.0, group = "MTF", display = display.data_window, tooltip = "Ambang hysteresis untuk direction flag. Lebih tinggi = lebih jarang flip direction. Default: 10.")
mtfDebug = input.bool(false, "Debug Mode (detail semua komponen)", group = "MTF", display = display.data_window, tooltip = "Jika aktif, tampilkan semua komponen MTF di Data Window untuk debugging.")

// Legacy MTF filter (retained for backward compat — trend row & narrative)
enableMtfFilter = input.bool(false, "Enable MTF Trend Filter (legacy)", group = "MTF", display = display.data_window, tooltip = "Legacy: filter tren Multi-Timeframe sederhana.")
mtfTimeframe = input.string("W", "MTF Timeframe (legacy)", options = ["W", "M"], group = "MTF", display = display.data_window, tooltip = "Timeframe legacy MTF. W = Weekly, M = Monthly.")

// ==========================================================
// 12. SETTINGS — Entry Trigger
// ==========================================================
entryTriggerMode = input.string("Composite Score", "Entry Trigger", options = ["Composite Score", "Pullback", "Breakout"], group = "Entry Trigger", display = display.data_window, tooltip = "Mode sinyal: Composite Score (zona 40/70), Pullback (entry saat retrace), atau Breakout (saat harga tembus level support/resistance).")

// ==========================================================
// 13. SETTINGS — Webhook / Alert Format
// ==========================================================
webhookFormat = input.string("Simple", "Alert Format", options = ["Simple", "JSON"], group = "Webhook", display = display.data_window, tooltip = "Format alert: Simple (teks biasa) atau JSON (PG|key=value untuk integrasi TradersPost/Pine Connector).")

// ==========================================================
// 14. COLOR THEMES
// ==========================================================
var color bgColor = na
var color headerColor = na
var color labelColor = na
var color scoreColor = na
var color tableBgColor = na
var color bullColor = na
var color bearColor = na
var color neutralColor = na
var color signalLineColor = na
var color dimTrend = na
var color dimMomentum = na
var color dimVolatility = na
var color dimVolume = na

if colorThemeInput == "Gelap"
    bgColor := color.rgb(0, 0, 0, 85)
    headerColor := color.rgb(38, 166, 154)
    labelColor := color.white
    scoreColor := color.rgb(38, 166, 154)
    tableBgColor := color.rgb(13, 22, 30, 90)
    bullColor := color.rgb(38, 166, 154)
    bearColor := color.rgb(239, 83, 80)
    neutralColor := color.rgb(255, 202, 40)
    signalLineColor := color.rgb(100, 100, 100)
    dimTrend := color.rgb(66, 165, 245)
    dimMomentum := color.rgb(255, 202, 40)
    dimVolatility := color.rgb(239, 83, 80)
    dimVolume := color.rgb(126, 87, 194)
else
    if colorThemeInput == "Terang"
        bgColor := color.rgb(255, 255, 255, 85)
        headerColor := color.rgb(0, 150, 136)
        labelColor := color.rgb(33, 33, 33)
        scoreColor := color.rgb(0, 150, 136)
        tableBgColor := color.rgb(245, 245, 245, 90)
        bullColor := color.rgb(0, 150, 136)
        bearColor := color.rgb(211, 47, 47)
        neutralColor := color.rgb(255, 160, 0)
        signalLineColor := color.rgb(158, 158, 158)
        dimTrend := color.rgb(33, 150, 243)
        dimMomentum := color.rgb(255, 193, 7)
        dimVolatility := color.rgb(244, 67, 54)
        dimVolume := color.rgb(156, 39, 176)
    else
        if colorThemeInput == "Bursa Hijau"
            bgColor := color.rgb(0, 30, 0, 85)
            headerColor := color.rgb(76, 175, 80)
            labelColor := color.white
            scoreColor := color.rgb(76, 175, 80)
            tableBgColor := color.rgb(0, 20, 0, 90)
            bullColor := color.rgb(76, 175, 80)
            bearColor := color.rgb(244, 67, 54)
            neutralColor := color.rgb(255, 235, 59)
            signalLineColor := color.rgb(100, 100, 100)
            dimTrend := color.rgb(129, 199, 132)
            dimMomentum := color.rgb(255, 235, 59)
            dimVolatility := color.rgb(239, 83, 80)
            dimVolume := color.rgb(186, 104, 200)
        else
            if colorThemeInput == "Biru Nusantara"
                bgColor := color.rgb(0, 20, 50, 85)
                headerColor := color.rgb(41, 98, 255)
                labelColor := color.white
                scoreColor := color.rgb(41, 98, 255)
                tableBgColor := color.rgb(0, 10, 30, 90)
                bullColor := color.rgb(41, 98, 255)
                bearColor := color.rgb(255, 82, 82)
                neutralColor := color.rgb(255, 202, 40)
                signalLineColor := color.rgb(100, 100, 100)
                dimTrend := color.rgb(100, 181, 246)
                dimMomentum := color.rgb(255, 202, 40)
                dimVolatility := color.rgb(239, 83, 80)
                dimVolume := color.rgb(179, 136, 255)
            else
                bgColor := color.rgb(30, 20, 0, 85)
                headerColor := color.rgb(255, 193, 7)
                labelColor := color.rgb(33, 33, 33)
                scoreColor := color.rgb(255, 193, 7)
                tableBgColor := color.rgb(20, 15, 0, 90)
                bullColor := color.rgb(76, 175, 80)
                bearColor := color.rgb(244, 67, 54)
                neutralColor := color.rgb(255, 193, 7)
                signalLineColor := color.rgb(158, 158, 158)
                dimTrend := color.rgb(255, 183, 77)
                dimMomentum := color.rgb(255, 213, 79)
                dimVolatility := color.rgb(239, 83, 80)
                dimVolume := color.rgb(206, 147, 216)

// ==========================================================
// 10. UTILITY FUNCTIONS
// ==========================================================
f_secure(input, def) => na(input) ? def : input

f_scoreHigher(float val, float min, float max) =>
    na(val) ? na : math.max(0, math.min(100, (val - min) / (max - min) * 100))

f_scoreLower(float val, float min, float max) =>
    na(val) ? na : math.max(0, math.min(100, (max - val) / (max - min) * 100))

f_scoreRange(float val, float min, float max, float idealLow, float idealHigh) =>
    if na(val)
        na
    else
        if val >= idealLow and val <= idealHigh
            100.0
        else
            if val < idealLow
                if val <= min
                    0.0
                else
                    (val - min) / (idealLow - min) * 100
            else
                if val >= max
                    0.0
                else
                    (max - val) / (max - idealHigh) * 100


f_colorScore(float score) =>
    if na(score)
        color.gray
    else
        if score >= 70
            bullColor
        else
            if score >= 40
                neutralColor
            else
                bearColor

f_signalText(float score, string lang) =>
    if na(score)
        lang == "Indonesia" ? "N/A" : "N/A"
    else
        if score >= 70
            lang == "Indonesia" ? "BULLISH" : "BULLISH"
        else
            if score >= 40
                lang == "Indonesia" ? "NETRAL" : "NEUTRAL"
            else
                lang == "Indonesia" ? "BEARISH" : "BEARISH"

Overview

This base module declares the indicator in a separate pane and stores the display and calculation settings used by the dashboard. It covers table position, font size, compact to detailed mode, language, and color theme. Trend inputs set three EMAs, SuperTrend, and ADX. Momentum inputs set RSI, MACD, and Stochastic levels. The repository describes trend, momentum, volatility, and volume scoring, but this file only defines settings and does not plot signals or place trades.

Details

Published by

akhmfz on GitHub

Type

Indicator, Pine Script v6

Draws

Separate pane below the chart

Category

Screeners & dashboards, Trend, Oscillators & momentum, Volatility & bands

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
Table PositionstringTop RighttablePositionInput
Font Sizeint1fontSizeInput
ModestringStandardmodeInput
BahasastringIndonesiabahasaInput
Color ThemestringGelapcolorThemeInput
EMA Fast Periodint20emaFastPeriod
EMA Mid Periodint50emaMidPeriod
EMA Slow Periodint200emaSlowPeriod
SuperTrend Factorfloat3.0superTrendFactor
SuperTrend ATR Periodint10superTrendPeriod
ADX Lengthint14adxLength
ADX Thresholdint25adxThreshold
Show all 40 settings
SettingTypeDefaultVariable
RSI Lengthint14rsiLength
RSI Overboughtint70rsiOb
RSI Oversoldint30rsiOs
MACD Fastint12macdFast
MACD Slowint26macdSlow
MACD Signalint9macdSignal
Stochastic Kint14stochK
Stochastic Dint3stochD
Stoch Overboughtint80stochOb
Stoch Oversoldint20stochOs
ATR Lengthint14atrLength
Bollinger Lengthint20bbLength
Bollinger Multiplierfloat2.0bbMult
Choppiness Lengthint14chopLength
Volume MA Lengthint20volMaLength
Volume Spike Multiplierfloat2.0volSpikeMult
Trend Weight (%)int30weightTrend
Momentum Weight (%)int30weightMomentum
Volatility Weight (%)int20weightVolatility
Volume Weight (%)int20weightVolume
Enable Smart Money FlowboolfalseenableSmartMoney
SM Weight (%)int20weightSmartMoney
SM Volume Z-Thresholdfloat2.5smVolumeThreshold
SM Lookback Periodint20smPeriod
Min Bars Between Signalsint5minSignalBars
Signal FilterstringDisabledsignalFilterMode
Confirm on Bar ClosebooltrueconfirmOnBarClose
Show Risk LevelsbooltrueshowRiskLevels
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

The Adaptive Cycle Detector estimates the dominant market cycle from WaveTrend oscillator zero-crossing frequency and applies smoothing to recommend adaptive indicator lengths. Fast markets with frequent crossings receive shorter lengths while slow swing marke

Indicator v6 Oscillators & momentumVolatility & bands
Updated yesterday · MIT GitHub repository of Adaptive Cycle Detector [WavesUnchained]

Manias, Panics and Crashes

by MeridianAlgo
9 stars

Manias, Panics and Crashes is a separate-pane market regime indicator that quantifies market sentiment and systemic risk. It processes technical metrics including RSI, moving averages, and volume alongside optional intermarket data such as VIX volatility and c

Indicator v6 Oscillators & momentumVolatility & bands
Updated 4 months ago · MIT GitHub repository of Manias, Panics and Crashes

Elton's Screener

by eltonaguiar
4 stars

Elton's Screener is an indicator that runs in a separate pane and scores one of twenty selectable strategies, or auto-selects a route from the symbol type. It filters signals by a minimum confidence level and a higher-timeframe EMA trend alignment. ATR multipl

Indicator v6 Screeners & dashboardsOscillators & momentum Repaints
Updated today · None stated GitHub repository of Elton's Screener

DEPV2 C6 Gölge Kasa

by YuceSezar89
1 stars

This indicator evaluates signal performance and multi-timeframe market dynamics through a shadow bankroll tracking framework. It measures market conditions across trend, momentum ROC Z-scores, ATR volatility expansion, and volume flow, alongside multi-timefram

Indicator v6 TrendOscillators & momentum
Updated 11 days ago · None stated GitHub repository of DEPV2 C6 Gölge Kasa

Market Regime Dashboard

by vantradelabs
2 stars

The Market Regime Dashboard is a multi-timeframe dashboard indicator that evaluates market conditions across three user-defined timeframes. It measures four core dimensions: trend strength using ADX and DI direction, momentum using RSI z-scores, volatility via

Indicator v6 Screeners & dashboardsTrend
Updated 2 months ago · Custom licence GitHub repository of Market Regime Dashboard

This indicator evaluates market conditions across four user-defined timeframes by combining RSI, MACD crossovers, triple EMA trend filters, Bollinger Band boundaries, and volume spikes. It computes aggregate bullish and bearish scores, plotting buy and sell si

Indicator v5 Screeners & dashboardsOscillators & momentum
Updated 8 months ago · None stated GitHub repository of Multi-Timeframe Trade Signal Indicator

More indicators

Trade Your Charts With a Regulated Broker

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

Compare brokers