TJR asia session sweep//@version=5
strategy("TJR asia session sweep", "TJR Asia Sweep", overlay=true, max_lines_count=500, max_labels_count=500)
// Input settings
show_asian = input.bool(true, "Show Asian Session", group="Visual Settings")
show_london = input.bool(true, "Show London Session", group="Visual Settings")
show_swing_points = input.bool(true, "Show Asian Swing Points", group="Visual Settings")
show_market_structure = input.bool(true, "Show Market Structure", group="Visual Settings")
show_bos = input.bool(true, "Show Break of Structure", group="Visual Settings")
// Session Time Settings
asian_start_hour_input = input.int(22, "Asian Session Start Hour", minval=0, maxval=23, group="Session Times")
asian_end_hour_input = input.int(3, "Asian Session End Hour", minval=0, maxval=23, group="Session Times")
london_start_hour_input = input.int(3, "London Session Start Hour", minval=0, maxval=23, group="Session Times")
london_end_hour_input = input.int(8, "London Session End Hour", minval=0, maxval=23, group="Session Times")
session_timezone = input.string("America/New_York", "Session Timezone", options= , group="Session Times")
// Risk Management Settings
use_atr_sl = input.bool(false, "Use ATR Multiplier for Stop Loss", group="Risk Management")
atr_length = input.int(14, "ATR Length", minval=1, maxval=50, group="Risk Management")
atr_multiplier = input.float(2.0, "ATR Multiplier for Stop Loss", minval=0.5, maxval=10.0, group="Risk Management")
force_london_close = input.bool(true, "Force Close at London Session End", group="Risk Management")
cutoff_minutes = input.int(60, "Minutes Before Session End to Stop New Trades", minval=0, maxval=300, group="Risk Management")
// Position Sizing Settings
position_sizing_method = input.string("USD Risk", "Position Sizing Method", options= , group="Position Sizing")
usd_risk_per_trade = input.float(100.0, "USD Risk Per Trade", minval=1.0, maxval=10000.0, group="Position Sizing")
fixed_contracts = input.float(1.0, "Fixed Number of Contracts", minval=0.01, maxval=1000.0, step=0.01, group="Position Sizing")
// Color settings
asian_color = input.color(color.red, "Asian Session Color")
london_color = input.color(color.blue, "London Session Color")
swing_high_color = input.color(color.orange, "Swing High Color")
swing_low_color = input.color(color.lime, "Swing Low Color")
bullish_structure_color = input.color(color.green, "Bullish Structure Color")
bearish_structure_color = input.color(color.red, "Bearish Structure Color")
bos_color = input.color(color.orange, "Break of Structure Color")
// Line settings
line_width = input.int(2, "Line Width", minval=1, maxval=5)
// ATR calculation for stop loss
atr = ta.atr(atr_length)
// Position size calculation function
calculate_position_size(entry_price, stop_loss_price) =>
var float position_size = na
if position_sizing_method == "Fixed Contracts"
position_size := fixed_contracts
else // USD Risk method
stop_distance = math.abs(entry_price - stop_loss_price)
if stop_distance > 0
// Calculate position size based on USD risk per trade
// For forex: position_size = risk_amount / (stop_distance * point_value)
// For most forex pairs, point value = 1 (since we're dealing with price differences directly)
position_size := usd_risk_per_trade / stop_distance
else
position_size := fixed_contracts // Fallback to fixed contracts if stop distance is 0
position_size
// Session time definitions (using input variables)
asian_start_hour = asian_start_hour_input
asian_end_hour = asian_end_hour_input
london_start_hour = london_start_hour_input
london_end_hour = london_end_hour_input
// Get current hour using selected timezone
current_hour = hour(time, session_timezone)
// Previous hour for transition detection
prev_hour = hour(time , session_timezone)
// Session transition detection
asian_start = current_hour == asian_start_hour and prev_hour != asian_start_hour
asian_end = current_hour == asian_end_hour and prev_hour != asian_end_hour
london_start = current_hour == london_start_hour and prev_hour != london_start_hour
london_end = current_hour == london_end_hour and prev_hour != london_end_hour
// Session activity detection
asian_active = (current_hour >= asian_start_hour) or (current_hour < asian_end_hour)
london_active = (current_hour >= london_start_hour) and (current_hour < london_end_hour)
// Session boxes - keep previous sessions visible
var box asian_session_box = na
var box london_session_box = na
// Create Asian session box
if show_asian and asian_start
// Create new box at session start (previous box remains visible)
asian_session_box := box.new(bar_index, high, bar_index + 1, low,
border_color=asian_color, bgcolor=color.new(asian_color, 90),
border_width=2, border_style=line.style_solid)
// Pre-calculate session highs and lows for consistency
asian_session_length = asian_active and not na(asian_session_box) ? bar_index - box.get_left(asian_session_box) + 1 : 1
current_asian_high = ta.highest(high, asian_session_length)
current_asian_low = ta.lowest(low, asian_session_length)
// Update Asian session box continuously during session
if show_asian and asian_active and not na(asian_session_box)
box.set_right(asian_session_box, bar_index)
// Update box to contain session highs and lows
box.set_top(asian_session_box, current_asian_high)
box.set_bottom(asian_session_box, current_asian_low)
// Create London session box
if show_london and london_start
// Create new box at session start (previous box remains visible)
london_session_box := box.new(bar_index, high, bar_index + 1, low,
border_color=london_color, bgcolor=color.new(london_color, 90),
border_width=2, border_style=line.style_solid)
// Pre-calculate London session highs and lows for consistency
london_session_length = london_active and not na(london_session_box) ? bar_index - box.get_left(london_session_box) + 1 : 1
current_london_high = ta.highest(high, london_session_length)
current_london_low = ta.lowest(low, london_session_length)
// Update London session box continuously during session
if show_london and london_active and not na(london_session_box)
box.set_right(london_session_box, bar_index)
// Update box to contain session highs and lows
box.set_top(london_session_box, current_london_high)
box.set_bottom(london_session_box, current_london_low)
// Asian Session Swing Points Detection
var float asian_session_high = na
var float asian_session_low = na
var int asian_high_bar = na
var int asian_low_bar = na
// Asian Session Absolute High/Low for TP levels
var float asian_absolute_high = na
var float asian_absolute_low = na
var line asian_high_line = na
var line asian_low_line = na
var label asian_high_label = na
var label asian_low_label = na
var bool high_broken = false
var bool low_broken = false
// London Session High/Low tracking for stop loss
var float london_session_high = na
var float london_session_low = na
// Market structure tracking variables
var string breakout_direction = na // "bullish" or "bearish"
var float last_hh_level = na // Last Higher High level
var float last_hl_level = na // Last Higher Low level
var float last_ll_level = na // Last Lower Low level
var float last_lh_level = na // Last Lower High level
var int structure_count = 0
var string last_structure_type = na // "HH", "HL", "LL", "LH"
// Legacy variables for compatibility
var float last_swing_high = na
var float last_swing_low = na
var int last_high_bar = na
var int last_low_bar = na
// Market structure state tracking
var float pending_high = na
var float pending_low = na
var int pending_high_bar = na
var int pending_low_bar = na
var bool waiting_for_confirmation = false
// Break of Structure tracking variables
var float most_recent_hl = na
var float most_recent_lh = na
var int most_recent_hl_bar = na
var int most_recent_lh_bar = na
var bool bos_detected = false
// Trading variables
var bool trade_taken = false
// Trade visualization boxes (based on Casper strategy approach)
var box current_profit_box = na
var box current_sl_box = na
// Update swing points during Asian session
if asian_active and show_swing_points
// Always track absolute high/low for both TP levels and breakout detection
if na(asian_absolute_high) or high > asian_absolute_high
asian_absolute_high := high
if na(asian_absolute_low) or low < asian_absolute_low
asian_absolute_low := low
// Use absolute high/low for breakout levels (simplified logic)
if na(asian_session_high) or high > asian_session_high
asian_session_high := high
asian_high_bar := bar_index
if na(asian_session_low) or low < asian_session_low
asian_session_low := low
asian_low_bar := bar_index
// Track London session high/low for stop loss levels
if london_active
if na(london_session_high) or high > london_session_high
london_session_high := high
if na(london_session_low) or low < london_session_low
london_session_low := low
// Draw initial lines when Asian session ends
if asian_end and show_swing_points
if not na(asian_session_high) and not na(asian_high_bar)
// Draw extending line for high
asian_high_line := line.new(asian_high_bar, asian_session_high, bar_index + 200, asian_session_high,
color=swing_high_color, width=2, style=line.style_dashed, extend=extend.right)
asian_high_label := label.new(bar_index + 5, asian_session_high, "Asian High: " + str.tostring(asian_session_high, "#.####"), style=label.style_label_left, color=swing_high_color, textcolor=color.white, size=size.small)
if not na(asian_session_low) and not na(asian_low_bar)
// Draw extending line for low
asian_low_line := line.new(asian_low_bar, asian_session_low, bar_index + 200, asian_session_low,
color=swing_low_color, width=2, style=line.style_dashed, extend=extend.right)
asian_low_label := label.new(bar_index + 5, asian_session_low, "Asian Low: " + str.tostring(asian_session_low, "#.####"), style=label.style_label_left, color=swing_low_color, textcolor=color.white, size=size.small)
// Reset break flags for new session
high_broken := false
low_broken := false
// Check for breakouts during London session
if london_active and show_swing_points and not na(asian_session_high) and not na(asian_session_low)
// Check if Asian high is broken
if not high_broken and not low_broken and high > asian_session_high
high_broken := true
// Update high line to end at break point
if not na(asian_high_line)
line.set_x2(asian_high_line, bar_index)
line.set_extend(asian_high_line, extend.none)
// Remove the low line (first break wins)
if not na(asian_low_line)
line.delete(asian_low_line)
if not na(asian_low_label)
label.delete(asian_low_label)
// Add break marker
label.new(bar_index, asian_session_high * 1.001, "HIGH BREAK!",
style=label.style_label_down, color=color.red, textcolor=color.white, size=size.normal)
// Set breakout direction and initialize structure tracking
breakout_direction := "bullish"
last_swing_high := asian_session_high
last_swing_low := asian_session_low
last_high_bar := bar_index
structure_count := 0
// Check if Asian low is broken
if not low_broken and not high_broken and low < asian_session_low
low_broken := true
// Update low line to end at break point
if not na(asian_low_line)
line.set_x2(asian_low_line, bar_index)
line.set_extend(asian_low_line, extend.none)
// Remove the high line (first break wins)
if not na(asian_high_line)
line.delete(asian_high_line)
if not na(asian_high_label)
label.delete(asian_high_label)
// Add break marker
label.new(bar_index, asian_session_low * 0.999, "LOW BREAK!",
style=label.style_label_up, color=color.red, textcolor=color.white, size=size.normal)
// Set breakout direction and initialize structure tracking
breakout_direction := "bearish"
last_swing_high := asian_session_high
last_swing_low := asian_session_low
last_low_bar := bar_index
structure_count := 0
// Stop extending lines when London session ends (if not already broken)
if london_end and show_swing_points
if not high_broken and not na(asian_high_line)
line.set_x2(asian_high_line, bar_index)
line.set_extend(asian_high_line, extend.none)
if not low_broken and not na(asian_low_line)
line.set_x2(asian_low_line, bar_index)
line.set_extend(asian_low_line, extend.none)
// Force close all trades at London session end (if enabled)
if london_end and force_london_close
if strategy.position_size != 0
// Extend boxes immediately before session close to prevent timing issues
if not na(current_profit_box)
// Ensure minimum 8 bars width or extend to current bar, whichever is longer
box_left = box.get_left(current_profit_box)
min_right = box_left + 8
final_right = math.max(min_right, bar_index)
box.set_right(current_profit_box, final_right)
current_profit_box := na // Clear reference after extending
if not na(current_sl_box)
// Ensure minimum 8 bars width or extend to current bar, whichever is longer
box_left = box.get_left(current_sl_box)
min_right = box_left + 8
final_right = math.max(min_right, bar_index)
box.set_right(current_sl_box, final_right)
current_sl_box := na // Clear reference after extending
strategy.close_all(comment="London Close")
trade_taken := false // Reset trade flag for next session
// Market structure detection after breakout (only during London session and before first BoS)
if show_market_structure and not na(breakout_direction) and london_active and not bos_detected
// Bullish structure tracking (HH, HL alternating)
if breakout_direction == "bullish"
// Check for Higher High pattern: Bullish candle followed by bearish candle
pattern_high = math.max(high , high)
prev_hh = na(last_hh_level) ? last_swing_high : last_hh_level
// HH Detection: Only if we expect HH next (no last structure or last was HL)
if (na(last_structure_type) or last_structure_type == "HL") and close > open and close < open and pattern_high > prev_hh and close > prev_hh
// Check consolidation
is_too_close = not na(last_high_bar) and (bar_index - last_high_bar) <= 4
should_create_hh = true
if is_too_close and structure_count > 0 and pattern_high <= last_hh_level
should_create_hh := false
if should_create_hh
structure_count := structure_count + 1
label.new(bar_index - 1, high + (high * 0.0003), "HH" + str.tostring(structure_count),
style=label.style_none, color=color.new(color.white, 100),
textcolor=color.white, size=size.small)
last_hh_level := pattern_high
last_swing_high := pattern_high
last_high_bar := bar_index
last_structure_type := "HH"
// HL Detection: Only if we expect HL next (last was HH)
pattern_low = math.min(low , low)
prev_hl = na(last_hl_level) ? last_swing_low : last_hl_level
if last_structure_type == "HH" and close < open and close > open and pattern_low > prev_hl and close > prev_hl
// Check consolidation
is_too_close = not na(last_low_bar) and (bar_index - last_low_bar) <= 4
should_create_hl = true
if is_too_close and pattern_low <= last_hl_level
should_create_hl := false
if should_create_hl
structure_count := structure_count + 1
label.new(bar_index - 1, low - (low * 0.0003), "HL" + str.tostring(structure_count),
style=label.style_none, color=color.new(color.white, 100),
textcolor=color.white, size=size.small)
last_hl_level := pattern_low
most_recent_hl := pattern_low // Update most recent HL for BoS detection
most_recent_hl_bar := bar_index - 1 // Store HL bar position
last_low_bar := bar_index
last_structure_type := "HL"
// Bearish structure tracking (LL, LH alternating)
if breakout_direction == "bearish"
// Check for Lower Low pattern: Bearish candle followed by bullish candle
pattern_low = math.min(low , low)
prev_ll = na(last_ll_level) ? last_swing_low : last_ll_level
// LL Detection: Only if we expect LL next (no last structure or last was LH)
if (na(last_structure_type) or last_structure_type == "LH") and close < open and close > open and pattern_low < prev_ll and close < prev_ll
// Check consolidation
is_too_close = not na(last_low_bar) and (bar_index - last_low_bar) <= 4
should_create_ll = true
if is_too_close and structure_count > 0 and pattern_low >= last_ll_level
should_create_ll := false
if should_create_ll
structure_count := structure_count + 1
label.new(bar_index - 1, low - (low * 0.0003), "LL" + str.tostring(structure_count),
style=label.style_none, color=color.new(color.white, 100),
textcolor=color.white, size=size.small)
last_ll_level := pattern_low
last_swing_low := pattern_low
last_low_bar := bar_index
last_structure_type := "LL"
// LH Detection: Only if we expect LH next (last was LL)
pattern_high = math.max(high , high)
prev_lh = na(last_lh_level) ? last_swing_high : last_lh_level
if last_structure_type == "LL" and close > open and close < open and pattern_high < prev_lh and close < prev_lh
// Check consolidation
is_too_close = not na(last_high_bar) and (bar_index - last_high_bar) <= 4
should_create_lh = true
if is_too_close and pattern_high >= last_lh_level
should_create_lh := false
if should_create_lh
structure_count := structure_count + 1
label.new(bar_index - 1, high + (high * 0.0003), "LH" + str.tostring(structure_count),
style=label.style_none, color=color.new(color.white, 100),
textcolor=color.white, size=size.small)
last_lh_level := pattern_high
most_recent_lh := pattern_high // Update most recent LH for BoS detection
most_recent_lh_bar := bar_index - 1 // Store LH bar position
last_high_bar := bar_index
last_structure_type := "LH"
// Check if we're within the cutoff period before London session end
current_minute = minute(time, session_timezone)
london_end_time_minutes = london_end_hour * 60 // Convert London end hour to minutes
current_time_minutes = current_hour * 60 + current_minute // Current time in minutes
// Calculate minutes remaining in London session
london_session_minutes_remaining = london_end_time_minutes - current_time_minutes
// Handle day rollover case (e.g., if london_end is 8:00 (480 min) and current is 23:30 (1410 min))
if london_session_minutes_remaining < 0
london_session_minutes_remaining := london_session_minutes_remaining + (24 * 60) // Add 24 hours in minutes
// Only allow trades if more than cutoff_minutes remaining in London session
allow_new_trades = london_session_minutes_remaining > cutoff_minutes
// Break of Structure (BoS) Detection and Trading Logic - Only first BoS per London session and outside cutoff period
if show_bos and london_active and show_market_structure and not bos_detected and not trade_taken and allow_new_trades
// Bullish BoS: Price closes below the most recent HL (after bullish breakout) - SELL SIGNAL
if breakout_direction == "bullish" and not na(most_recent_hl) and not na(most_recent_hl_bar)
// Check minimum distance requirement (at least 4 candles between BoS and HL)
if close < most_recent_hl and (bar_index - most_recent_hl_bar) >= 4
// Draw dotted line from HL position to BoS point
line.new(most_recent_hl_bar, most_recent_hl, bar_index, most_recent_hl,
color=bos_color, width=2, style=line.style_dotted, extend=extend.none)
// Calculate center position for BoS label
center_bar = math.round((most_recent_hl_bar + bar_index) / 2)
// Draw BoS label below the line for HL break
label.new(center_bar, most_recent_hl - (most_recent_hl * 0.0005), "BoS",
style=label.style_none, color=color.new(color.white, 100),
textcolor=bos_color, size=size.normal)
// SELL ENTRY
if not na(london_session_high) and not na(asian_absolute_low)
// Calculate stop loss based on settings
stop_loss_level = use_atr_sl ? close + (atr * atr_multiplier) : london_session_high
take_profit_level = asian_absolute_low
entry_price = close
// Calculate position size based on user settings
position_size = calculate_position_size(entry_price, stop_loss_level)
strategy.entry("SELL", strategy.short, qty=position_size, comment="BoS Sell")
strategy.exit("SELL EXIT", "SELL", stop=stop_loss_level, limit=take_profit_level, comment="SL/TP")
// Create trade visualization boxes (TradingView style) - minimum 8 bars width
// Blue profit zone box (from entry to take profit)
current_profit_box := box.new(left=bar_index, top=take_profit_level, right=bar_index + 8, bottom=entry_price,
bgcolor=color.new(color.blue, 70), border_width=0)
// Red stop loss zone box (from entry to stop loss)
current_sl_box := box.new(left=bar_index, top=entry_price, right=bar_index + 8, bottom=stop_loss_level,
bgcolor=color.new(color.red, 70), border_width=0)
trade_taken := true
bos_detected := true // Mark BoS as detected for this session
// Bearish BoS: Price closes above the most recent LH (after bearish breakout) - BUY SIGNAL
if breakout_direction == "bearish" and not na(most_recent_lh) and not na(most_recent_lh_bar)
// Check minimum distance requirement (at least 4 candles between BoS and LH)
if close > most_recent_lh and (bar_index - most_recent_lh_bar) >= 4
// Draw dotted line from LH position to BoS point
line.new(most_recent_lh_bar, most_recent_lh, bar_index, most_recent_lh,
color=bos_color, width=1, style=line.style_dotted, extend=extend.none)
// Calculate center position for BoS label
center_bar = math.round((most_recent_lh_bar + bar_index) / 2)
// Draw BoS label above the line for LH break
label.new(center_bar, most_recent_lh + (most_recent_lh * 0.0005), "BoS",
style=label.style_none, color=color.new(color.white, 100),
textcolor=bos_color, size=size.normal)
// BUY ENTRY
if not na(london_session_low) and not na(asian_absolute_high)
// Calculate stop loss based on settings
stop_loss_level = use_atr_sl ? close - (atr * atr_multiplier) : london_session_low
take_profit_level = asian_absolute_high
entry_price = close
// Calculate position size based on user settings
position_size = calculate_position_size(entry_price, stop_loss_level)
strategy.entry("BUY", strategy.long, qty=position_size, comment="BoS Buy")
strategy.exit("BUY EXIT", "BUY", stop=stop_loss_level, limit=take_profit_level, comment="SL/TP")
// Create trade visualization boxes (TradingView style) - minimum 8 bars width
// Blue profit zone box (from entry to take profit)
current_profit_box := box.new(left=bar_index, top=entry_price, right=bar_index + 8, bottom=take_profit_level,
bgcolor=color.new(color.blue, 70), border_width=0)
// Red stop loss zone box (from entry to stop loss)
current_sl_box := box.new(left=bar_index, top=stop_loss_level, right=bar_index + 8, bottom=entry_price,
bgcolor=color.new(color.red, 70), border_width=0)
trade_taken := true
bos_detected := true // Mark BoS as detected for this session
// Position close detection for extending boxes (based on Casper strategy)
if barstate.isconfirmed and strategy.position_size == 0 and strategy.position_size != 0
// Extend trade visualization boxes to exact exit point when position closes
if not na(current_profit_box)
// Ensure minimum 8 bars width or extend to current bar, whichever is longer
box_left = box.get_left(current_profit_box)
min_right = box_left + 8
final_right = math.max(min_right, bar_index)
box.set_right(current_profit_box, final_right)
current_profit_box := na // Clear reference after extending
if not na(current_sl_box)
// Ensure minimum 8 bars width or extend to current bar, whichever is longer
box_left = box.get_left(current_sl_box)
min_right = box_left + 8
final_right = math.max(min_right, bar_index)
box.set_right(current_sl_box, final_right)
current_sl_box := na // Clear reference after extending
// Backup safety check - extend boxes if position is closed but boxes still active
if not na(current_profit_box) and strategy.position_size == 0
box_left = box.get_left(current_profit_box)
min_right = box_left + 8
final_right = math.max(min_right, bar_index)
box.set_right(current_profit_box, final_right)
current_profit_box := na
if not na(current_sl_box) and strategy.position_size == 0
box_left = box.get_left(current_sl_box)
min_right = box_left + 8
final_right = math.max(min_right, bar_index)
box.set_right(current_sl_box, final_right)
current_sl_box := na
// Reset everything when new Asian session starts
if asian_start and show_swing_points
asian_session_high := na
asian_session_low := na
asian_high_bar := na
asian_low_bar := na
// Reset absolute levels
asian_absolute_high := na
asian_absolute_low := na
asian_high_line := na
asian_low_line := na
asian_high_label := na
asian_low_label := na
high_broken := false
low_broken := false
// Reset London session levels
london_session_high := na
london_session_low := na
// Reset market structure tracking
breakout_direction := na
last_hh_level := na
last_hl_level := na
last_ll_level := na
last_lh_level := na
last_swing_high := na
last_swing_low := na
last_high_bar := na
last_low_bar := na
structure_count := 0
last_structure_type := na
pending_high := na
pending_low := na
pending_high_bar := na
pending_low_bar := na
waiting_for_confirmation := false
// Reset BoS tracking
most_recent_hl := na
most_recent_lh := na
most_recent_hl_bar := na
most_recent_lh_bar := na
bos_detected := false
// Reset trading
trade_taken := false
// Reset current trade boxes
current_profit_box := na
current_sl_box := na
// Debug info (optional)
show_debug = input.bool(false, "Show Debug Info")
if show_debug
var table debug_table = table.new(position.top_right, 2, 3, bgcolor=color.white, border_width=1)
if barstate.islast
table.cell(debug_table, 0, 0, "Current Hour:", text_color=color.black)
table.cell(debug_table, 1, 0, str.tostring(current_hour), text_color=color.black)
table.cell(debug_table, 0, 1, "Asian Active:", text_color=color.black)
table.cell(debug_table, 1, 1, str.tostring((current_hour >= asian_start_hour) or (current_hour < asian_end_hour)), text_color=color.black)
table.cell(debug_table, 0, 2, "London Active:", text_color=color.black)
table.cell(debug_table, 1, 2, str.tostring((current_hour >= london_start_hour) and (current_hour < london_end_hour)), text_color=color.black)
Indicadores y estrategias
Pullbacks CompletoThis indicator is a comprehensive Trend Following toolkit that combines two distinct, high-probability pullback strategies into a single, intelligent interface. It is designed to help traders identify precise entry points during corrections in established trends, filtering out low-quality noise.
The indicator features Smart Conflict Detection: if the two strategies generate opposing signals on the same candle, the system blocks the individual alerts and displays a Purple "X", warning the trader of market indecision.
Strategy 1: Stoch Pullback (Triangles)
Visual: Green/Red Triangles Logic:
Trend: Defined by the alignment of the Fast EMA (21) and Slow EMA (100).
The Setup: The indicator waits for the Stochastic RSI to enter an Overbought or Oversold zone.
Strict Filter: A signal is only valid if, while in the zone, the price physically tests the Fast EMA (closes against it). This filters out "shallow" pullbacks.
Trigger: The signal is fired when the Stochastic RSI crosses back out of the extreme zone, resuming the trend.
Strategy 2: Dave Landry Setup (Dots)
Visual: Green/Red Circles Logic:
Trend: Filtered by MACD Histogram momentum and the relation to the Fast EMA (21).
The Pattern: Looks for a correction of at least 2 candles making lower lows (for uptrends) or higher highs (for downtrends).
Trigger: Enters when the price breaks the high/low of the previous candle, provided it closes in favor of the EMA 21.
Anti-Climax Filter: Includes a "Stretched" filter to prevent buying/selling on exhausted "Elephant Bars" (huge candles that have already consumed the move).
Key Features
Dual Alert System: Receive specific alerts for "Pullback" or "Landry" setups.
Conflict Warning: If Strategy A says "Buy" and Strategy B says "Sell" simultaneously, a "Doubtful Signal" alert is triggered, and a purple Cross appears on the chart.
Smart Visibility: The indicator automatically hides or shows the Moving Averages depending on which strategies you have enabled in the settings.
Educational Tooltips: Hover over the "i" icons in the settings menu to read the rationale behind each specific filter.
How to Use
Green Triangle: Look for Long opportunities (Stoch Pullback).
Green Dot: Look for Long opportunities (Landry Breakout).
Red Triangle: Look for Short opportunities (Stoch Pullback).
Red Dot: Look for Short opportunities (Landry Breakout).
Purple X: Stay Out. The setups are conflicting (Trend vs. Momentum disagreement).
Configuration You can toggle each strategy on/off in the settings menu. You can also choose to display the Overbought/Oversold background zones to visualize where the Stoch Pullback is "arming".
30d Rolling TWAP (Hourly)code:
//@version=5
indicator("30d Rolling TWAP (Hourly)", overlay=true)
// Calculation: (High + Low + Close) / 3
typicalPrice = hlc3
// 30 days * 24 hours = 720 bars
length = 720
twap30 = ta.sma(typicalPrice, length)
// Plotting
plot(twap30, color=color.new(#2962FF, 0), title="30d Hourly TWAP", linewidth=2)
// Optional: Background highlight
fillColor = close > twap30 ? color.new(color.green, 90) : color.new(color.red, 90)
bgcolor(fillColor)
yaman short longThis indicator provides clear Long and Short signals to help traders identify potential market direction and trading opportunities with higher confidence.
It is designed to follow price momentum and trend strength, allowing traders to enter trades when the market shows clear directional bias. The indicator focuses on clean signals and avoids unnecessary noise, making it suitable for both beginners and experienced traders.
Key Features:
Clear Long and Short signals displayed on the chart
Helps identify potential trend continuation and reversals
Designed to reduce false signals during choppy market conditions
Suitable for scalping, intraday, and swing trading
Works across multiple markets and timeframes
How to Use:
Long Signal: Indicates potential upward movement when bullish conditions align
Short Signal: Indicates potential downward movement when bearish conditions align
Best used with proper stop-loss and risk management rules
Can be combined with support/resistance or higher timeframe confirmation
Best Markets:
Forex pairs
Gold (XAUUSD)
Cryptocurrencies
Indices
Notes:
Signals are generated after candle close
The indicator does not repaint
This tool is meant to assist decision-making, not guarantee profits
SHFE Silver Premium vs COMEX (USD/oz)This indicator measures the SHFE–COMEX silver premium/discount in USD per troy ounce.
SHFE silver is quoted in CNY per kilogram, so the script first converts SHFE:AG1! into USD/oz using the current USD/CNY exchange rate and the exact kg → troy oz factor (32.1507466). It then calculates:
Premium (USD/oz) = SHFE_USD/oz − COMEX_USD/oz
How to interpret:
Positive bars: SHFE is trading above COMEX (premium)
Negative bars: SHFE is trading below COMEX (discount)
Persistent regimes can reflect currency dynamics, regional liquidity, import/export constraints, and shifts in industrial demand.
How to use:
Add this indicator beneath the companion overlay indicator “SHFE Silver Price Discovery (USD/oz)” to keep the price chart readable while still visualizing divergence.
Watch for sustained premium expansions/contractions as inter-market confirmation signals, especially during volatile periods.
This indicator is intended for macro and inter-market analysis, not short-term scalping.
SA Range Rank NQ 1.13.2026 PM SESSION15 MINUTE — PREPARE / POSITION MODE
Developer Note: Bias & Position Framing
This daily view is preparatory, not executable.
The purpose of the Daily timeframe is to define directional bias, not entries.
It helps frame which side of the market deserves attention and which activity should be ignored.
The goal here is context, not action.
________________________________________
Purpose on Daily
The Daily timeframe is used to:
• Define directional bias for the week
• Prepare position-building zones
• Identify environments where participation is unnecessary or elevated-risk
• Reduce overtrading by narrowing focus
Daily charts answer one question only:
“If I participate this week, which side makes sense?”
________________________________________
What Matters Most (Public View)
SA Range Indicator (RI):
→ Is the market transitioning or trending?
→ Is energy building, releasing, or rotating?
SA ZoneEngine (visual context only):
→ Are daily moves aligned with higher-timeframe structure?
→ Is price operating with or against dominant bias?
These visuals explain environment, not decisions.
________________________________________
How to Interpret Public Daily Posts
• Daily is not timing
• Daily is not execution
• Daily is not a signal
Daily charts prepare the trader mentally and structurally by clarifying:
• what deserves patience
• what deserves caution
• what deserves no attention at all
________________________________________
Messaging Line
“Daily charts prepare the trade — they don’t execute it.”
________________________________________
SEO Intent
daily equity bias, position preparation, market structure analysis
________________________________________
🤝 For Those Who Find Value
If these daily posts help you see the market more clearly:
• Follow, boost, and share my scripts, Ideas, and MINDS posts
• Feel free to message me directly with questions or build requests
• Constructive feedback and collaboration are always welcome
For traders who want to go deeper, optional memberships may include:
• Additional signal access
• Early previews
• Occasional free tools and upgrades
🔗 Membership & Signals
trianchor.gumroad.com
________________________________________
________________________________________
⏱ 15-MIN — PREPARE / POSITION MODE
Developer Note: Setup Formation Phase
The 15-minute timeframe is where setups begin to form, not where they are acted on.
This view exists to separate developing structure from noise.
________________________________________
Purpose on 15-Minute
The 15-minute timeframe is used to:
• Spot trap-prone conditions
• Identify developing structure
• Observe compression, rotation, or early expansion
• Prepare for execution — without acting
This timeframe answers a different question:
“Is something forming — or is this noise?”
________________________________________
What Matters Most (Public View)
SA Range Indicator (RI):
→ Compression → expansion transitions
→ Energy buildup vs premature release
SA CloudRegimes (visual only):
→ Whether price behavior reflects continuation, pullback, or contraction
→ Whether movement is controlled or impulsive
These visuals describe behavior, not entries.
________________________________________
How to Interpret Public 15-Minute Posts
• 15m is setup formation
• 15m is environmental awareness
• 15m is not execution
Most errors occur when traders act before structure has finished forming.
This timeframe exists to slow that impulse down.
________________________________________
Messaging Line
“Preparation happens before the move — not during it.”
________________________________________
________________________________________
🤝 For Those Who Find Value
If these posts help you better recognize developing structure:
• Follow, boost, and share my scripts, Ideas, and MINDS posts
• Feel free to message me directly with questions or build requests
• Constructive feedback and collaboration are always welcome
For traders who want to go deeper, optional memberships may include:
• Additional signal access
• Early previews
• Occasional free tools and upgrades
🔗 Membership & Signals
trianchor.gumroad.com
15 Minute (15m) — Tactical Entry Alignment / “Permission + Timing”
Goal: Convert higher-timeframe permission into tradable timing.
How to use:
• Trade the first clean reclaim after a pullback.
• Avoid taking a reclaim if price is already extended far beyond the wake edge (late reclaim).
Best conditions:
• Works extremely well when:
o 1H agrees
o session structure is active (open/close windows)
o reclaim occurs near VWAP or a key level you already respect
Settings:
• dispMult 0.75–1.05
• reclaimWindow 6–14
• cooldown 3–6
🟠 15-MINUTE — Intraday Structure & Session Logic
1️⃣ Range Indicator (RI)
• Session compression → impulse likely
• Expansion → follow, don’t fade
Use:
Defines session behavior.
________________________________________
2️⃣ ZoneEngine (Structure)
• Filters session traps
• Explains failed breakouts
Use:
Keeps you aligned with real participation.
________________________________________
3️⃣ Cloud / Reclaim (Behavior)
• Identifies pullback vs continuation
• Reclaim confirms acceptance
Use:
Contextual confirmation.
________________________________________
4️⃣ Stop-Hunt Proxy
• Session liquidity sweeps
• Common near opens and transitions
Use:
Stop-hunt + compression = likely session impulse.
BarCoreLibrary "BarCore"
BarCore is a foundational library for technical analysis, providing essential functions for evaluating the structural properties of candlesticks and inter-bar relationships.
It prioritizes ratio-based metrics (0.0 to 1.0) over absolute prices, making it asset-agnostic and ideal for robust pattern recognition, momentum analysis, and volume-weighted pressure evaluation.
Key modules:
- Structure & Range: High-precision bar and body metrics with relative positioning.
- Wick Dynamics: Absolute and relative wick analysis for identifying price rejection.
- Inter-bar Logic: Containment, coverage, and quantitative price overlap (Ratio-based).
- Gap Intelligence: Real body and price gaps with customizable significance thresholds.
- Flow & Pressure: Volume-weighted buying/selling pressure and Money Flow metrics.
isBuyingBar()
Checks if the bar is a bullish (up) bar, where close is greater than open.
Returns: bool True if the bar closed higher than it opened.
isSellingBar()
Checks if the bar is a bearish (down) bar, where close is less than open.
Returns: bool True if the bar closed lower than it opened.
barMidpoint()
Calculates the absolute midpoint of the bar's total range (High + Low) / 2.
Returns: float The midpoint price of the bar.
barRange()
Calculates the absolute size of the bar's total range (High to Low).
Returns: float The absolute difference between high and low.
barRangeMidpoint()
Calculates half of the bar's total range size.
Returns: float Half the bar's range size.
realBodyHigh()
Returns the higher price between the open and close.
Returns: float The top of the real body.
realBodyLow()
Returns the lower price between the open and close.
Returns: float The bottom of the real body.
realBodyMidpoint()
Calculates the absolute midpoint of the bar's real body.
Returns: float The midpoint price of the real body.
realBodyRange()
Calculates the absolute size of the bar's real body.
Returns: float The absolute difference between open and close.
realBodyRangeMidpoint()
Calculates half of the bar's real body size.
Returns: float Half the real body size.
upperWickRange()
Calculates the absolute size of the upper wick.
Returns: float The range from high to the real body high.
lowerWickRange()
Calculates the absolute size of the lower wick.
Returns: float The range from the real body low to low.
openRatio()
Returns the location of the open price relative to the bar's total range (0.0 at low to 1.0 at high).
Returns: float The ratio of the distance from low to open, divided by the total range.
closeRatio()
Returns the location of the close price relative to the bar's total range (0.0 at low to 1.0 at high).
Returns: float The ratio of the distance from low to close, divided by the total range.
realBodyRatio()
Calculates the ratio of the real body size to the total bar range.
Returns: float The real body size divided by the bar range. Returns 0 if barRange is 0.
upperWickRatio()
Calculates the ratio of the upper wick size to the total bar range.
Returns: float The upper wick size divided by the bar range. Returns 0 if barRange is 0.
lowerWickRatio()
Calculates the ratio of the lower wick size to the total bar range.
Returns: float The lower wick size divided by the bar range. Returns 0 if barRange is 0.
upperWickToBodyRatio()
Calculates the ratio of the upper wick size to the real body size.
Returns: float The upper wick size divided by the real body size. Returns 0 if realBodyRange is 0.
lowerWickToBodyRatio()
Calculates the ratio of the lower wick size to the real body size.
Returns: float The lower wick size divided by the real body size. Returns 0 if realBodyRange is 0.
totalWickRatio()
Calculates the ratio of the total wick range (Upper Wick + Lower Wick) to the total bar range.
Returns: float The total wick range expressed as a ratio of the bar's total range. Returns 0 if barRange is 0.
isBodyExpansion()
Checks if the current bar's real body range is larger than the previous bar's real body range (body expansion).
Returns: bool True if realBodyRange() > realBodyRange() .
isBodyContraction()
Checks if the current bar's real body range is smaller than the previous bar's real body range (body contraction).
Returns: bool True if realBodyRange() < realBodyRange() .
isWithinPrevBar(inclusive)
Checks if the current bar's range is entirely within the previous bar's range.
Parameters:
inclusive (bool) : If true, allows equality (<=, >=). Default is false.
Returns: bool True if High < High AND Low > Low .
isCoveringPrevBar(inclusive)
Checks if the current bar's range fully covers the entire previous bar's range.
Parameters:
inclusive (bool) : If true, allows equality (<=, >=). Default is false.
Returns: bool True if High > High AND Low < Low .
isWithinPrevBody(inclusive)
Checks if the current bar's real body is entirely inside the previous bar's real body.
Parameters:
inclusive (bool) : If true, allows equality (<=, >=). Default is false.
Returns: bool True if the current body is contained inside the previous body.
isCoveringPrevBody(inclusive)
Checks if the current bar's real body fully covers the previous bar's real body.
Parameters:
inclusive (bool) : If true, allows equality (<=, >=). Default is false.
Returns: bool True if the current body fully covers the previous body.
isOpenWithinPrevBody(inclusive)
Checks if the current bar's open price falls within the real body range of the previous bar.
Parameters:
inclusive (bool) : If true, includes the boundary prices. Default is false.
Returns: bool True if the open price is between the previous bar's real body high and real body low.
isCloseWithinPrevBody(inclusive)
Checks if the current bar's close price falls within the real body range of the previous bar.
Parameters:
inclusive (bool) : If true, includes the boundary prices. Default is false.
Returns: bool True if the close price is between the previous bar's real body high and real body low.
isPrevOpenWithinBody(inclusive)
Checks if the previous bar's open price falls within the current bar's real body range.
Parameters:
inclusive (bool) : If true, includes the boundary prices. Default is false.
Returns: bool True if open is between the current bar's real body high and real body low.
isPrevCloseWithinBody(inclusive)
Checks if the previous bar's closing price falls within the current bar's real body range.
Parameters:
inclusive (bool) : If true, includes the boundary prices. Default is false.
Returns: bool True if close is between the current bar's real body high and real body low.
isOverlappingPrevBar()
Checks if there is any price overlap between the current bar's range and the previous bar's range.
Returns: bool True if the current bar's range has any intersection with the previous bar's range.
bodyOverlapRatio()
Calculates the percentage of the current real body that overlaps with the previous real body.
Returns: float The overlap ratio (0.0 to 1.0). 1.0 means the current body is entirely within the previous body's price range.
isCompletePriceGapUp()
Checks for a complete price gap up where the current bar's low is strictly above the previous bar's high, meaning there is zero price overlap between the two bars.
Returns: bool True if the current low is greater than the previous high.
isCompletePriceGapDown()
Checks for a complete price gap down where the current bar's high is strictly below the previous bar's low, meaning there is zero price overlap between the two bars.
Returns: bool True if the current high is less than the previous low.
isRealBodyGapUp()
Checks for a gap between the current and previous real bodies.
Returns: bool True if the current body is completely above the previous body.
isRealBodyGapDown()
Checks for a gap between the current and previous real bodies.
Returns: bool True if the current body is completely below the previous body.
gapRatio()
Calculates the percentage difference between the current open and the previous close, expressed as a decimal ratio.
Returns: float The gap ratio (positive for gap up, negative for gap down). Returns 0 if the previous close is 0.
gapPercentage()
Calculates the percentage difference between the current open and the previous close.
Returns: float The gap percentage (positive for gap up, negative for gap down). Returns 0 if previous close is 0.
isGapUp()
Checks for a basic gap up, where the current bar's open is strictly higher than the previous bar's close. This is the minimum condition for a gap up.
Returns: bool True if the current open is greater than the previous close (i.e., gapRatio is positive).
isGapDown()
Checks for a basic gap down, where the current bar's open is strictly lower than the previous bar's close. This is the minimum condition for a gap down.
Returns: bool True if the current open is less than the previous close (i.e., gapRatio is negative).
isSignificantGapUp(minRatio)
Checks if the current bar opened significantly higher than the previous close, as defined by a minimum percentage ratio.
Parameters:
minRatio (float) : The minimum required gap percentage ratio. Default is 0.03 (3%).
Returns: bool True if the gap ratio (open vs. previous close) is greater than or equal to the minimum ratio.
isSignificantGapDown(minRatio)
Checks if the current bar opened significantly lower than the previous close, as defined by a minimum percentage ratio.
Parameters:
minRatio (float) : The minimum required gap percentage ratio. Default is 0.03 (3%).
Returns: bool True if the absolute value of the gap ratio (open vs. previous close) is greater than or equal to the minimum ratio.
trueRangeComponentHigh()
Calculates the absolute distance from the current bar's High to the previous bar's Close, representing one of the components of the True Range.
Returns: float The absolute difference: |High - Close |.
trueRangeComponentLow()
Calculates the absolute distance from the current bar's Low to the previous bar's Close, representing one of the components of the True Range.
Returns: float The absolute difference: |Low - Close |.
isUpperWickDominant(minRatio)
Checks if the upper wick is significantly long relative to the total range.
Parameters:
minRatio (float) : Minimum ratio of the wick to the total bar range. Default is 0.7 (70%).
Returns: bool True if the upper wick dominates the bar's range.
isUpperWickNegligible(maxRatio)
Checks if the upper wick is very small relative to the total range.
Parameters:
maxRatio (float) : Maximum ratio of the wick to the total bar range. Default is 0.05 (5%).
Returns: bool True if the upper wick is negligible.
isLowerWickDominant(minRatio)
Checks if the lower wick is significantly long relative to the total range.
Parameters:
minRatio (float) : Minimum ratio of the wick to the total bar range. Default is 0.7 (70%).
Returns: bool True if the lower wick dominates the bar's range.
isLowerWickNegligible(maxRatio)
Checks if the lower wick is very small relative to the total range.
Parameters:
maxRatio (float) : Maximum ratio of the wick to the total bar range. Default is 0.05 (5%).
Returns: bool True if the lower wick is negligible.
isSymmetric(maxTolerance)
Checks if the upper and lower wicks are roughly equal in length.
Parameters:
maxTolerance (float) : Maximum allowable percentage difference between the two wicks. Default is 0.15 (15%).
Returns: bool True if wicks are symmetric within the tolerance level.
isMarubozuBody(minRatio)
Candle with a very large body relative to the total range (minimal wicks).
Parameters:
minRatio (float) : Minimum body size ratio. Default is 0.9 (90%).
Returns: bool True if the bar has minimal wicks (Marubozu body).
isLargeBody(minRatio)
Candle with a large body relative to the total range.
Parameters:
minRatio (float) : Minimum body size ratio. Default is 0.6 (60%).
Returns: bool True if the bar has a large body.
isSmallBody(maxRatio)
Candle with a small body relative to the total range.
Parameters:
maxRatio (float) : Maximum body size ratio. Default is 0.4 (40%).
Returns: bool True if the bar has small body.
isDojiBody(maxRatio)
Candle with a very small body relative to the total range (indecision).
Parameters:
maxRatio (float) : Maximum body size ratio. Default is 0.1 (10%).
Returns: bool True if the bar has a very small body.
isLowerWickExtended(minRatio)
Checks if the lower wick is significantly extended relative to the real body size.
Parameters:
minRatio (float) : Minimum required ratio of the lower wick length to the real body size. Default is 2.0 (Lower wick must be at least twice the body's size).
Returns: bool True if the lower wick's length is at least `minRatio` times the size of the real body.
isUpperWickExtended(minRatio)
Checks if the upper wick is significantly extended relative to the real body size.
Parameters:
minRatio (float) : Minimum required ratio of the upper wick length to the real body size. Default is 2.0 (Upper wick must be at least twice the body's size).
Returns: bool True if the upper wick's length is at least `minRatio` times the size of the real body.
isStrongBuyingBar(minCloseRatio, maxOpenRatio)
Checks for a bar with strong bullish momentum (open near low, close near high), indicating high conviction.
Parameters:
minCloseRatio (float) : Minimum required ratio for the close location (relative to range, e.g., 0.7 means close must be in the top 30%). Default is 0.7 (70%).
maxOpenRatio (float) : Maximum allowed ratio for the open location (relative to range, e.g., 0.3 means open must be in the bottom 30%). Default is 0.3 (30%).
Returns: bool True if the bar is bullish, opened in the low extreme, and closed in the high extreme.
isStrongSellingBar(maxCloseRatio, minOpenRatio)
Checks for a bar with strong bearish momentum (open near high, close near low), indicating high conviction.
Parameters:
maxCloseRatio (float) : Maximum allowed ratio for the close location (relative to range, e.g., 0.3 means close must be in the bottom 30%). Default is 0.3 (30%).
minOpenRatio (float) : Minimum required ratio for the open location (relative to range, e.g., 0.7 means open must be in the top 30%). Default is 0.7 (70%).
Returns: bool True if the bar is bearish, opened in the high extreme, and closed in the low extreme.
isWeakBuyingBar(maxCloseRatio, maxBodyRatio)
Identifies a bar that is technically bullish but shows significant weakness, characterized by a failure to close near the high and a small body size.
Parameters:
maxCloseRatio (float) : Maximum allowed ratio for the close location relative to the range (e.g., 0.6 means the close must be in the bottom 60% of the bar's range). Default is 0.6 (60%).
maxBodyRatio (float) : Maximum allowed ratio for the real body size relative to the bar's range (e.g., 0.4 means the body is small). Default is 0.4 (40%).
Returns: bool True if the bar is bullish, but its close is weak and its body is small.
isWeakSellingBar(minCloseRatio, maxBodyRatio)
Identifies a bar that is technically bearish but shows significant weakness, characterized by a failure to close near the low and a small body size.
Parameters:
minCloseRatio (float) : Minimum required ratio for the close location relative to the range (e.g., 0.4 means the close must be in the top 60% of the bar's range). Default is 0.4 (40%).
maxBodyRatio (float) : Maximum allowed ratio for the real body size relative to the bar's range (e.g., 0.4 means the body is small). Default is 0.4 (40%).
Returns: bool True if the bar is bearish, but its close is weak and its body is small.
balanceOfPower()
Measures the net pressure of buyers vs. sellers within the bar, normalized to the bar's range.
Returns: float A value between -1.0 (strong selling) and +1.0 (strong buying), representing the strength and direction of the close relative to the open.
buyingPressure()
Measures the net buying volume pressure based on the close location and volume.
Returns: float A numerical value representing the volume weighted buying pressure.
sellingPressure()
Measures the net selling volume pressure based on the close location and volume.
Returns: float A numerical value representing the volume weighted selling pressure.
moneyFlowMultiplier()
Calculates the Money Flow Multiplier (MFM), which is the price component of Money Flow and CMF.
Returns: float A normalized value from -1.0 (strong selling) to +1.0 (strong buying), representing the net directional pressure.
moneyFlowVolume()
Calculates the Money Flow Volume (MFV), which is the Money Flow Multiplier weighted by the bar's volume.
Returns: float A numerical value representing the volume-weighted money flow. Positive = buying dominance; negative = selling dominance.
isAccumulationBar()
Checks for basic accumulation on the current bar, requiring both positive Money Flow Volume and a buying bar (closing higher than opening).
Returns: bool True if the bar exhibits buying dominance through its internal range location and is a buying bar.
isDistributionBar()
Checks for basic distribution on the current bar, requiring both negative Money Flow Volume and a selling bar (closing lower than opening).
Returns: bool True if the bar exhibits selling dominance through its internal range location and is a selling bar.
QUARTERS THEORY XAUUSDThe “Quarter Theory XAUUSD” indicator on TradingView is designed to automatically plot horizontal price levels in $25 increments on your chart, providing traders with a clear visual representation of key psychological and technical price points. These levels are particularly useful for instruments like XAU/USD, where price often reacts to round numbers, forming support and resistance zones that can be leveraged for both scalping and swing trading strategies. By showing all $25 increments as horizontal white lines, the indicator ensures that traders can quickly identify potential entry and exit points, without the need for manual drawing or repeated calculations.
The indicator works by calculating the nearest $25 multiple relative to the current market price and then drawing horizontal lines across the chart for all increments within a defined range. This range can be customized to suit the instrument being traded; for example, for gold (XAU/USD), a typical range might extend from 0 to 5000, covering all practical price levels that could be relevant in both high and low market conditions. By using Pine Script’s persistent variables, the indicator efficiently creates these lines only once at the start of the chart, avoiding unnecessary resource usage and preventing TradingView from slowing down, which can happen if lines are redrawn every bar.
From a trading perspective, these levels serve multiple purposes. For scalpers, the $25 increments act as micro support and resistance points, helping to determine short-term price reactions and potential breakout zones. Scalpers can use these levels to enter positions with tight stop-loss orders just beyond a level and take profits near the next $25 increment, which aligns with common price behavior patterns in highly liquid instruments. For swing traders, the same levels provide broader context, allowing them to identify areas where price might pause or reverse over several days. Swing traders can use these levels to align trades with the prevailing trend, particularly when combined with other indicators such as moving averages or trendlines.
Another key advantage of the Quarterly Levels indicator is its simplicity and visual clarity. By plotting lines in a uniform white color and extending them to the right, the chart remains clean and easy to read, allowing traders to focus on price action and market dynamics rather than cluttered technical drawings. This visual consistency also helps in backtesting and strategy development, as traders can quickly see how price interacts with each level over time. Additionally, the use of round-number increments leverages the psychological tendencies of market participants, as many traders place stop orders or entry points near these levels, making them natural zones of interest.
Overall, the Quarterly Levels indicator combines efficiency, clarity, and practical trading utility into a single tool. It streamlines chart analysis, highlights meaningful price zones, and supports both scalping and swing trading approaches, making it an essential addition to a trader’s toolkit. By understanding how to integrate these levels into trading strategies, traders can make more informed decisions, manage risk effectively, and identify high-probability trade setups across various market conditions.
LEVENT: Lifetime Estimation via Efficiency-Regime EventLEVENT — Lifetime Estimation via Efficiency-Regime Event Transitions
LEVENT is a research-grade indicator that estimates the remaining structural lifetime of the current market regime.
Unlike trend, volatility, or momentum tools, LEVENT does not measure price movement — it measures how long the current market structure is likely to survive before breaking.
This script implements the LEVENT model published on Zenodo (Bülent Duman, 2026) and is built on top of the open-source DERYA (Dynamic Efficiency Regime Yield Analyzer) microstructural efficiency framework.
What LEVENT measures
LEVENT outputs a single continuous variable L that represents the remaining survival capacity of the active efficiency regime.
High L → the current regime has strong structural endurance
Falling L → the regime is consuming its capacity
L → 0 → regime exhaustion and elevated probability of transition
This makes LEVENT a forward-looking structural time variable, not a price indicator.
What is inside this script
This implementation contains the following components:
1. DERYA (open-source microstructure efficiency)
DERYA is computed from OHLC data as:
Net close-to-close movement divided by total intrabar range
It is smoothed with an EMA and normalized over a rolling window to produce a bounded efficiency state (0–100).
This is an open-source indicator and is explicitly credited in the LEVENT paper.
2. Transition Strength (S)
S measures how unstable the regime is by combining:
the slope of DERYA
the acceleration of DERYA
This is not RSI, MACD, or ATR — it is a state-transition intensity metric.
3. Regime Engine
Markets are classified into four structural regimes:
Expansion
Exhaustion
Collapse
Base / Recovery
A debounce + persistence filter is used to avoid noise-based flickering.
4. Structural Lifetime (LEVENT L)
Each regime is assigned a capacity (Λ) and a fragility (α).
LEVENT then evolves as a jump-and-countdown survival process:
On regime change → L resets to full capacity
Inside a regime → L decays deterministically
High instability → faster decay
This is not a moving average, oscillator, or probability estimate — it is a structural survival clock.
How to use LEVENT
LEVENT is designed to be used as a regime-health overlay, not a buy/sell trigger.
Typical uses:
Detect late-stage trends when L is low
Avoid initiating positions when the regime is near collapse
Compare structural stability across assets
Combine with price, trend, or volume systems
Do not use LEVENT alone as a trading signal.
LEVENT tells you “how long the structure may last”, not “where price will go.”
Visuals
Background colors show the current regime
The LEVENT line shows remaining structural lifetime
A table displays the active regime and current L value
Important notes
LEVENT is not RSI, MACD, ATR, or trend
LEVENT does not predict price direction
LEVENT does not issue entry/exit signals
LEVENT is a research-grade structural model
The DERYA component used here is an open-source microstructural efficiency estimator and is credited accordingly.
Risk and disclaimer
This script is provided for research and analytical purposes only.
It is not financial advice and must not be used as a standalone trading system.
Markets are uncertain.
All trading decisions and risks remain entirely the responsibility of the user.
LEVENT: Lifetime Estimation via Efficiency-regime Event Transitions
Introducing a Regime-Dependent Structural Lifetime Estimator for Financial Markets Using OHLC Data
Author: DUMAN,Bülent
Affiliation: Independent Researcher
zenodo.org
Korean Trading Value in 100M KRW (KRX Standard)이 지표는 한국 시장(KOSPI, KOSDAQ) 투자자들을 위해 거래대금을 가장 직관적인 '억 원' 단위로 변환하여 보여줍니다.
주요 특징:
직관적인 수치: 우측 가격축(Y축)에 표시되는 숫자 '1'은 '1억 원'을 의미합니다. (예: 1000 = 1000억)
KRX 표준 최적화: 한국거래소 기준에 맞춰 금액을 환산하여 시장 주도주와 자금 유입을 즉각 파악할 수 있습니다. (참고: 본 지표는 KRX 데이터를 기준으로 하며, NXT 거래대금은 포함되지 않습니다.)
깔끔한 UI: 차트 화면을 가리는 라벨을 제거하고 트레이딩뷰 기본 색상 테마를 유지하여 가독성이 뛰어납니다.
실시간 확인: trackprice 기능을 통해 현재 진행 중인 봉의 거래대금을 우측 라벨에서 실시간으로 확인할 수 있습니다.
*****
This indicator is designed for the Korean stock market (KRX), converting trading values into the most intuitive unit for local traders: 'Eok' (100 million KRW).
Key Features:
Intuitive Scaling: The numbers on the Y-axis represent 100 million KRW per unit. (e.g., 1000 = 100 billion KRW)
KRX Standard Optimized: Easily identify market leaders and capital flow based on KRX data. (Note: This indicator is based on KRX standards and does not include NXT trading value.)
Clean UI: Minimizes on-screen clutter and maintains TradingView's default color theme for maximum readability.
Real-time Tracking: The trackprice feature allows you to monitor the current bar's trading value directly on the price scale in real-time.
Trading Value (Auto-Unit: K/M/B) with Price LabelsThis is a simple yet powerful indicator that calculates and displays the Trading Value (Price × Volume) instead of just trading quantity. It helps traders identify where the real "big money" is flowing.
By. Ninggimhee
Range Marker by Vinay SinghThis indicator marks back and forth range on given timeframes. good indicator to test range breakout.
MNQ BandsMNQ Bands – Execution Clean MNQ Bands – Execution Clean MNQ Bands – Execution Clean MNQ Bands – Execution Clean MNQ Bands – Execution Clean MNQ Bands – Execution Clean
Crypto Swing 5% Volatility Scanner (v6)The script is a work in progress and will look for crypto that has a min +-5% Volatility for day trading.
EMA 9/24/50/100/200 with Labels on chart lines This Pine Script® v6 indicator plots five distinct Exponential Moving Averages (EMAs) onto a single trading chart to help identify trend direction and momentum. By calculating the 9, 24, 50, 100, and 200-period averages, the script allows you to visualize short-term price action alongside long-term support and resistance levels. It uses a color-coded hierarchy and varying line thicknesses to make the different timeframes easy to distinguish at a glance.
with labels on the lines
EMA 9/24/50/100/200 v6This Pine Script® v6 indicator plots five distinct Exponential Moving Averages (EMAs) onto a single trading chart to help identify trend direction and momentum. By calculating the 9, 24, 50, 100, and 200-period averages, the script allows you to visualize short-term price action alongside long-term support and resistance levels. It uses a color-coded hierarchy and varying line thicknesses to make the different timeframes easy to distinguish at a glance.
Extreme Streak Leaderboard (Top 7)This script ranks the Top 7 consecutive decline streaks over 5 years (1825 days). It precisely tracks start dates, percentage drops, and subsequent rebound strength via a clean table, helping traders identify historical oversold patterns and high-probability reversal opportunities based on extreme price action."
Strat Master FTFC v1Setup Ready alert fires on the close of the last “setup” candle (the candle right before the entry trigger candle).
Entry alert still fires intrabar when the current candle becomes 2U/2D and takes out the trigger.
Below is the fully updated, compiling Pine v5 script with:
All your reversal patterns
Real FTFC (0–3) + flip alerts
Calls/Puts bias + strike
Gap-safe takeout (no crossover)
NEW: Setup Ready alerts for every pattern (bar-close only)
Signal Architect Stop-Hunt ProxySignal Architect™ — Developer Note
These daily posts are intentional.
They are designed to help potential users visually observe consistency—not just in outcomes, but in process—across multiple futures products, market conditions, and timeframes, using the Stop Hunt Indicator alongside my proprietary Signal Architect™ framework.
The goal is simple:
To show how structure, behavior, and probability repeat—every day—despite a constantly changing market.
If you follow these posts over time, you will begin to recognize that:
• The same behaviors appear across different futures contracts
• The same reactions occur on multiple timeframes
• The same structural traps and stop events repeat regardless of volatility regime
That consistency is not coincidence.
Consistency is the signal.
Over time, that consistency should become familiar—
and familiarity should become your edge.
________________________________________
🧠 What You’re Seeing (And Why It Matters)
This indicator includes a limited visual preview of a proprietary power signal I have personally developed and refined across:
• Futures
• Algorithmic trading systems
• Options structure
• Equity market behavior
Every tool I release is built around one core principle:
Clarity of direction without over-promising or over-fitting.
That is why all Signal Architect™ tools emphasize:
• Market structure first
• High-probability directional context
• Clear, visual risk framing
• No predictive claims
• No curve-fit illusions
What you see publicly is not the full system—only controlled, educational previews meant to demonstrate how structure and probability align in real markets.
________________________________________
📊 Background & Scope
Over the years, I have personally developed 800+ programs, including:
• Equity systems
• Futures strategies
• Options structure tools
• Dividend & income frameworks
• Portfolio construction and allocation logic
This includes 40+ Nasdaq-100 trading bots, several operating under extremely strict rule-sets and controlled deployment conditions.
Nothing shared publicly represents my complete internal framework.
Public posts exist for education, observation, and pattern recognition—not signals, not advice, and not promises.
________________________________________
🤝 For Those Who Find Value
If these daily posts help you see the market more clearly:
• Follow, boost, and share my scripts, Ideas, and MINDS posts
• Feel free to message me directly with questions or build requests
• Constructive feedback and collaboration are always welcome
For traders who want to go deeper, optional memberships may include:
• Additional signal access
• Early previews
• Occasional free tools and upgrades
🔗 Membership & Signals:
trianchor.gumroad.com
________________________________________
⚠️ Final Note
Everything published publicly is educational and analytical only.
Markets carry risk.
Discipline, patience, and risk management always come first.
Watch the consistency.
Study the structure.
Let the market repeat itself.
— Signal Architect™
________________________________________
🔗 Personally Developed GPT Tools
• AuctionFlow GPT
chatgpt.com
• Signal Architect™ Gamma Desk – Market Intelligence
chatgpt.com
• Gamma Squeeze Watchtower™
chatgpt.com
1H Buy: Engulf @ 20EMA + Vol + HTF Bull + Break Highbuy signal on the one hour for bullish engulfing strategy. Forms at the 20EMA, volume expansion, higher timeframe (4h) is bullish, next candle breaks engulfing candle.
SVE Pivot Points (v2) //@version=6
indicator(title="SVE Pivot Points", overlay=true, max_lines_count=500)
// Input Parameters
agg_period = input.timeframe("D", title="Aggregation period")
extend_bars = input.int(50, title="Bars to extend into future", minval=1, maxval=500)
show_labels = input.bool(true, title="Show Labels")
// Line width
line_width = input.int(1, title="Line Width", minval=1, maxval=4)
// Detect new aggregation period
bool new_agg_bar = bool(ta.change(time(agg_period)))
// Fetch previous period's high, low, close
ph = request.security(syminfo.tickerid, agg_period, high , barmerge.gaps_off, barmerge.lookahead_on)
pl = request.security(syminfo.tickerid, agg_period, low , barmerge.gaps_off, barmerge.lookahead_on)
pc = request.security(syminfo.tickerid, agg_period, close , barmerge.gaps_off, barmerge.lookahead_on)
// Calculate pivot points
pp = (ph + pl + pc) / 3
r1 = 2 * pp - pl
r2 = pp + (ph - pl)
r3 = 2 * pp + (ph - 2 * pl)
s1 = 2 * pp - ph
s2 = pp - (ph - pl)
s3 = 2 * pp - (2 * ph - pl)
// Calculate mean levels
r1m = (pp + r1) / 2
r2m = (r1 + r2) / 2
r3m = (r2 + r3) / 2
s1m = (pp + s1) / 2
s2m = (s1 + s2) / 2
s3m = (s2 + s3) / 2
// Previous high and low
hh = ph
ll = pl
// Colors
color_r = color.red
color_s = color.green
color_pp = color.blue
color_hl = color.gray
// Persistent line variables
var line line_r3 = na
var line line_r3m = na
var line line_r2 = na
var line line_r2m = na
var line line_r1 = na
var line line_r1m = na
var line line_hh = na
var line line_pp = na
var line line_ll = na
var line line_s1m = na
var line line_s1 = na
var line line_s2m = na
var line line_s2 = na
var line line_s3m = na
var line line_s3 = na
// Persistent label variables
var label lbl_r3 = na
var label lbl_r3m = na
var label lbl_r2 = na
var label lbl_r2m = na
var label lbl_r1 = na
var label lbl_r1m = na
var label lbl_hh = na
var label lbl_pp = na
var label lbl_ll = na
var label lbl_s1m = na
var label lbl_s1 = na
var label lbl_s2m = na
var label lbl_s2 = na
var label lbl_s3m = na
var label lbl_s3 = na
// Function to create or update line
create_line(line ln, float price, color col) =>
line.new(bar_index, price, bar_index + extend_bars, price, color=col, width=line_width)
// Function to create label
create_label(float price, string txt, color col) =>
label.new(bar_index + extend_bars, price, txt, style=label.style_label_left, color=color.new(col, 90), textcolor=col, size=size.small)
// On new aggregation period, delete old lines and create new ones
if new_agg_bar
// Delete old lines
line.delete(line_r3)
line.delete(line_r3m)
line.delete(line_r2)
line.delete(line_r2m)
line.delete(line_r1)
line.delete(line_r1m)
line.delete(line_hh)
line.delete(line_pp)
line.delete(line_ll)
line.delete(line_s1m)
line.delete(line_s1)
line.delete(line_s2m)
line.delete(line_s2)
line.delete(line_s3m)
line.delete(line_s3)
// Delete old labels
if show_labels
label.delete(lbl_r3)
label.delete(lbl_r3m)
label.delete(lbl_r2)
label.delete(lbl_r2m)
label.delete(lbl_r1)
label.delete(lbl_r1m)
label.delete(lbl_hh)
l






















