Strategy · Pine Script v6 · On the chart

TQQQ MA+TSI

by yalili8521

The TQQQ MA+TSI strategy executes trades based on triple simple moving average alignment combined with True Strength Index (TSI) divergence or momentum filters.

View on GitHub

GitHub stars2on the repository
Pine versionv6current
Lines of code357
Settings23inputs
LicenceNone stated
Last update7 days ago21 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 strategy, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart. The trades and results appear in the Strategy Tester tab; adjust the settings with the gear icon.

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

Designed primarily for intraday stock trading, it evaluates price accumulation across fast, mid, and slow moving averages within configurable New York session hours. Entries require confirmation from TSI momentum or hidden divergence within a set recency window. Exits are managed through percentage-based initial stop losses, trailing stops, break-even triggers, and session force-closes. It draws directly on the price chart.

Details

Published by

yalili8521 on GitHub

Type

Strategy, Pine Script v6

Draws

On the price chart

Category

Trend, Oscillators & momentum, Moving averages, Divergence

Markets

Stocks

Timeframes

M1-M5, M15-H1

Risk Notes

  • The strategy enters trades without a stop loss

Settings

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

SettingTypeDefaultVariable
Fast MA (5)int5ma_fast_len
Mid MA (10)int10ma_mid_len
Slow MA (20)int20ma_slow_len
Accumulation lookback barsint10acc_lookback
Min bars rising (of lookback)int6acc_min_bars
Max single bar % (reject spikes)float1.05max_bar_size
Morning entry onlybooltrueuse_session
Session start hour (ET)int9session_start
Session start minuteint30session_start_min
Session end hour (ET)int11session_end
Session end minuteint0session_end_min
BE trigger %float1.50be_trigger_pct
Show all 23 settings
SettingTypeDefaultVariable
Initial Stop Loss %float1.50sl_pct
Trailing Stop %float0.75trail_pct
Allow shortsbooltrueallow_short
Bars between tradesint8cooldown_bars
TSI Long Lengthint13tsi_long_len
TSI Short Lengthint7tsi_short_len
TSI Signal Lengthint7tsi_sig_len
Pivot Lookback/Forwardint5pivot_len
Max bars between pivotsint50max_pivot_dist
TSI Filter ModestringRecent Divergencetsi_mode
Divergence recency (bars)int15tsi_recency
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 strategy executes long positions by combining a 200-period EMA trend filter, Stochastic RSI oversold crosses, and Williams Alligator retracements, supplemented by RSI divergence detection. It triggers long entries when the price trades above the 200 EMA w

Strategy v4 TrendOscillators & momentum
Updated 3 years ago · Apache-2.0 GitHub repository of 200 EMA + Alligator + Stochastic Long Strategy

This strategy draws on the price chart and manages long and short entries around pivot trendlines. It filters signals with three configurable moving averages, Stochastic RSI, a higher-timeframe Stochastic RSI, and optional RSI divergence. A session window can

Strategy v5 TrendOscillators & momentum Repaints
Updated 5 months ago · None stated GitHub repository of Pivot Trendlines with Divergence Scanner Strategy

MML Multi Indikator Script

by theupslidedown
2 stars

This strategy plots a range filter and high and low target bands on the price chart, and colors bars from filter direction. Inputs cover a backtest date window, WaveTrend Cipher B channel and average lengths, overbought and oversold levels, divergence threshol

Strategy v4 TrendOscillators & momentum
Updated 3 years ago · None stated GitHub repository of MML Multi Indikator Script
1 stars

The strategy calculates the Stochastic oscillator using specified K and D periods, then detects bullish and bearish divergences between price pivots and the D line. Bullish signals occur when price forms lower lows while Stochastic forms higher lows within the

Strategy v6 Oscillators & momentumDivergence
Updated 2 months ago · None stated GitHub repository of TN Stochastic Causal Divergence
330 stars

MACD + Divergences [Alorse] is a momentum strategy that calculates the MACD oscillator and identifies regular and hidden divergences using pivot high and low points. It filters trade signals with dual Exponential Moving Averages (EMA 150 and 600) to ensure tra

Strategy v4 Oscillators & momentumDivergence Repaints
Updated 2 months ago · None stated GitHub repository of MACD + Divergences [Alorse]

Trust Me Bro Strategy

by moonyroy
2 stars

A trading strategy that uses an RSI state machine tracking 50-level crossovers, pullbacks, and hidden divergences. Entries require confirmation from optional confluence filters, including an EMA touch, Fibonacci retracement zones, and Ichimoku cloud conditions

Strategy v6 Oscillators & momentumDivergence
Updated 7 weeks ago · MIT GitHub repository of Trust Me Bro Strategy

More strategys

Trade Your Charts With a Regulated Broker

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

Compare brokers