1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
3Paste over the templateCreate a new indicator, select all of the template text and paste. Press Save and give it a name.
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
Pro Quant Desk (US) v1 calculates market regime metrics including macro risk gauges using SPY, QQQ, and equal-weight RSP breadth proxies, two-layer relative strength against sector ETFs and the S&P 500, Stan Weinstein stage classification using a 30-week moving average, and Stovall economic sector rotation. It also incorporates position sizing rules based on portfolio equity and risk limits, alongside anti-FOMO pivot extension checks. Key outputs and decision verdicts display in an on-screen dashboard.
Macro risk gauge evaluating SPY, QQQ, and equal-weight breadth
Two-layer relative strength comparing stock to sector ETF and SPX
Stan Weinstein stage analysis based on 30-week moving average
Stovall sector rotation tracking against economic cycle phases
Position sizing calculator with anti-FOMO pivot extension warnings
The inputs you can change from the gear icon on the chart. Defaults are the author's.
Setting
Type
Default
Variable
S&P 500 proxy (SPY)
symbol
AMEX:SPY
sym_spx
Nasdaq 100 proxy (QQQ)
symbol
NASDAQ:QQQ
sym_ndx
Breadth proxy (equal-weight S&P)
symbol
AMEX:RSP
sym_breadth
Breadth lookback (bars)
int
20
breadth_len
This stock's sector ETF
symbol
AMEX:XLK
sym_sector
RS lookback (bars)
int
50
rs_len
This stock's sector
string
Technology
sector
US Economic Phase
string
Early Recovery
stovall_phase
Portfolio Value (USD)
float
50000.0
portfolio_usd
Max Position % of Portfolio
float
8.0
max_pos_pct
Target Position %
float
5.0
tgt_pos_pct
Max Risk per Trade %
float
1.0
risk_per_trd
Show all 22 settings
Setting
Type
Default
Variable
Assumed Stop Distance %
float
7.0
stop_dist_p
Marks Cycle Score
int
5
marks_score
Pivot lookback (bars)
int
15
fomo_lookback
FOMO if price > N% above pivot
float
1.0
fomo_extend_pct
Show Dashboard (top-right)
bool
true
show_table
Show FOMO warning label
bool
true
show_fomo_lbl
Show Weinstein stage marker
bool
true
show_stage
Table Background
color
#0a0e27
tbl_bg
Header Background
color
#16213e
tbl_hdr_bg
Text Size
string
Normal
txt_size_in
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.
This indicator classifies each bar as bull, bear, or sideways from a rolling log return compared with adjustable percentage thresholds. It paints a regime ribbon on the price chart, shows a current-regime banner, and labels state changes after a minimum hold.
This indicator overlays an intraday SPX and ES chart with a midnight session range, regular-trading-hours opening levels, and a VWAP projection box. It draws the midnight high, mid, and low, flags edge rejections within an absolute tolerance, and plots optiona
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
This indicator classifies the market into gamma regime types (negative gamma trend, positive gamma mean-reversion, or transition) by calculating a composite score based on daily ATR ratios, session VWAP crossover frequencies, and opening range displacement. It
Calculates exponential moving averages for fast, pivot, and slow lengths along with optional 50, 100, and 200 simple moving average context lines. It visualizes bullish and bearish ribbon fills on the main price chart alongside MACD calculations to generate ea
Apex Trend & Liquidity Master calculates a trend cloud using customizable moving averages expanded by a volatility multiplier directly on the main price chart. It identifies dynamic support and resistance liquidity zones from swing high and low pivots, extendi