
양 시간대 오프닝 영역을 뚫고 스톱 손실을 추적하는 양적 거래 전략은 런던과 뉴욕 거래 시간대 오프닝 15분 전의 가격 영역을 기반으로 한 브레이크 거래 시스템이다. 이 전략은 두 주요 금융 센터의 오프닝 초반의 가격 동력을 포착하여 가격이 처음 15분 동안 형성된 최고점이나 낮은 시점에 진입하여 거래한다. 전략의 핵심 특징은 손실을 추적하는 스톱 메커니즘을 적용하여 수익을 보호하면서 수익을 지속적으로 증가시킬 수 있습니다. 이 전략은 동시에 거래 품질을 높이기 위해 선택 가능한 균일 선 필터링 조건을 제공합니다.
이 전략의 작동 메커니즘은 두 가지 중요한 시간대에 걸쳐 진행됩니다. 런던 시장이 열립니다 (뉴욕 시간 3시 ~ 3시 15분) 그리고 뉴욕 시장이 열립니다 (뉴욕 시간 9시 30분 ~ 9시 45분). 전략 작업 과정은 다음과 같습니다.
전략의 핵심 논리는 거래 시기의 초기 가격 방향의 돌파구를 포착하는 데 있습니다. 이것은 일반적으로 추세적 인 행동을 나타낼 수 있습니다. 추적 스톱스 메커니즘을 사용하여 전략은 이미 수익을 창출하는 동시에 수익성있는 거래를 계속 할 수 있습니다.
심층 분석을 통해 이 전략은 다음과 같은 장점을 가지고 있습니다.
이 전략은 합리적으로 설계되었지만, 다음과 같은 잠재적인 위험들이 있습니다.
전략적 분석을 바탕으로 다음과 같은 최적화 방안이 제시되었습니다.
쌍시장 개시 간격 브레이크 트래킹 스톱 손실량화 거래 전략은 런던과 뉴욕의 두 개의 금융 센터의 개시 시간을 대상으로 설계된 브레이크 거래 시스템이다. 개시 초기 가격 움직임과 방향을 캡처하여, 트래킹 스톱 메커니즘과 결합하여, 이 전략은 위험을 통제하면서 수익 잠재력을 극대화 할 수 있습니다. 가짜 브레이크와 시장 환경 의존 등의 위험이 있지만, 합리적인 파라미터 설정과 추가 필터링 조건을 통해 전략의 안정성과 수익성을 더욱 향상시킬 수 있습니다. 이 전략은 특히 변동성이 높고 유동성이 풍부한 시장에 적합하며, 거래자는 자신의 위험 용량과 거래 목표에 따라 적절하게 조정해야합니다.
/*backtest
start: 2024-04-27 00:00:00
end: 2025-04-25 08:00:00
period: 1h
basePeriod: 1h
exchanges: [{"eid":"Futures_Binance","currency":"SOL_USDT"}]
*/
//@version=6
strategy("ORB-LD-NY-Trail Strategy", overlay=true,
default_qty_type=strategy.fixed, default_qty_value=1,
calc_on_order_fills=true, calc_on_every_tick=true)
// =========================
// USER INPUTS
// =========================
riskReward = input.float(2.0, "Risk-Reward Ratio", minval=1.0)
minBoxSize = input.float(2.0, "Minimum Box Size (points)")
trailStopTicks = input.int(8, "Trailing Stop (ticks)", minval=1)
useEmaFilter = input.bool(false, "Use 5-min EMA Filter?")
tickSize = syminfo.mintick // auto-detect min tick for symbol
trailStopOffset = trailStopTicks * tickSize
emaSource = request.security(syminfo.tickerid, "5", ta.ema(close, 200)) // 5-min chart EMA
// =========================
// SESSION TIMES
// =========================
londonStart = timestamp("America/New_York", year, month, dayofmonth, 3, 0)
londonEnd = timestamp("America/New_York", year, month, dayofmonth, 3, 15)
nyStart = timestamp("America/New_York", year, month, dayofmonth, 9, 30)
nyEnd = timestamp("America/New_York", year, month, dayofmonth, 9, 45)
inLondon = time >= londonStart and time <= londonEnd
inNY = time >= nyStart and time <= nyEnd
// =========================
// ONE TRADE PER SESSION FLAGS
// =========================
var bool londonTraded = false
var bool nyTraded = false
// =========================
// LONDON BOX
// =========================
var float londonHigh = na
var float londonLow = na
var float londonBoxHigh = na
var float londonBoxLow = na
if inLondon
if na(londonHigh)
londonBoxHigh := na
londonBoxLow := na
londonTraded := false
londonHigh := na(londonHigh) ? high : math.max(londonHigh, high)
londonLow := na(londonLow) ? low : math.min(londonLow, low)
if not inLondon and na(londonBoxHigh) and not na(londonHigh) and not na(londonLow)
londonBoxHigh := londonHigh
londonBoxLow := londonLow
londonHigh := na
londonLow := na
if time > londonEnd and not na(londonBoxHigh) and not londonTraded
boxRange = londonBoxHigh - londonBoxLow
if boxRange >= minBoxSize
// Standard SL/TP logic
longSL = londonBoxHigh - boxRange
longTP = londonBoxHigh + boxRange * riskReward
shortSL = londonBoxLow + boxRange
shortTP = londonBoxLow - boxRange * riskReward
// === LONDON LONG ===
condLong1 = close[1] <= londonBoxHigh
condLong2 = close > londonBoxHigh
condLong3 = (not useEmaFilter) or (close > emaSource)
if condLong1 and condLong2 and condLong3
strategy.entry("London Long", strategy.long)
strategy.exit("Exit London Long", from_entry="London Long",
stop=longSL, limit=longTP,
trail_points=trailStopOffset)
londonTraded := true
// === LONDON SHORT ===
condShort1 = close[1] >= londonBoxLow
condShort2 = close < londonBoxLow
condShort3 = (not useEmaFilter) or (close < emaSource)
if not londonTraded and condShort1 and condShort2 and condShort3
strategy.entry("London Short", strategy.short)
strategy.exit("Exit London Short", from_entry="London Short",
stop=shortSL, limit=shortTP,
trail_points=trailStopOffset)
londonTraded := true
// =========================
// NY BOX
// =========================
var float nyHigh = na
var float nyLow = na
var float nyBoxHigh = na
var float nyBoxLow = na
if inNY
if na(nyHigh)
nyBoxHigh := na
nyBoxLow := na
nyTraded := false
nyHigh := na(nyHigh) ? high : math.max(nyHigh, high)
nyLow := na(nyLow) ? low : math.min(nyLow, low)
if not inNY and na(nyBoxHigh) and not na(nyHigh) and not na(nyLow)
nyBoxHigh := nyHigh
nyBoxLow := nyLow
nyHigh := na
nyLow := na
if time > nyEnd and not na(nyBoxHigh) and not nyTraded
boxRange = nyBoxHigh - nyBoxLow
if boxRange >= minBoxSize
longSL = nyBoxHigh - boxRange
longTP = nyBoxHigh + boxRange * riskReward
shortSL = nyBoxLow + boxRange
shortTP = nyBoxLow - boxRange * riskReward
// === NY LONG ===
condNYLong1 = close[1] <= nyBoxHigh
condNYLong2 = close > nyBoxHigh
condNYLong3 = (not useEmaFilter) or (close > emaSource)
if condNYLong1 and condNYLong2 and condNYLong3
strategy.entry("NY Long", strategy.long)
strategy.exit("Exit NY Long", from_entry="NY Long",
stop=longSL, limit=longTP,
trail_points=trailStopOffset)
nyTraded := true
// === NY SHORT ===
condNYShort1 = close[1] >= nyBoxLow
condNYShort2 = close < nyBoxLow
condNYShort3 = (not useEmaFilter) or (close < emaSource)
if not nyTraded and condNYShort1 and condNYShort2 and condNYShort3
strategy.entry("NY Short", strategy.short)
strategy.exit("Exit NY Short", from_entry="NY Short",
stop=shortSL, limit=shortTP,
trail_points=trailStopOffset)
nyTraded := true
// Visual session background
bgcolor(inLondon ? color.new(color.fuchsia, 85) : na)
bgcolor(inNY ? color.new(color.green, 85) : na)