
이 전략은 68주기 지수 이동 평균 ((EMA) 에 기반한 트렌드 추적 거래 시스템으로, 동적 스톱스 메커니즘을 결합한다. 이 전략은 가격과 EMA의 교차를 통해 시장 트렌드를 식별하고, 초기 스톱스 및 추적 스톱스를 사용하여 위험을 관리하고, 트렌드 시장에서 안정적인 거래를 실현한다.
전략은 68주기 EMA를 핵심 지표로 사용하여 시장의 추세를 판단한다. 가격이 EMA를 상향으로 통과하면 다단계 포지션을 열고, 가격이 EMA를 하향으로 통과하면 공백 포지션을 열는다. 위험을 효과적으로 관리하기 위해 전략은 2층의 스톱 보호 장치를 설정한다. 초기 스톱 손실과 추적 스톱 손실.
흔들림 시장 위험: 가로판 흔들림 시장에서 자주 중지 손실을 유발할 수 있습니다. 제안된 조치: ADX와 같은 트렌드 확인 지표를 추가하기.
폭락 위험: 시장의 폭락으로 인해 실제 스톱로드 가격이 예상보다 벗어날 수 있다. 권장 조치: 옵션의 사용이나 지분 규모의 조정을 고려하십시오.
변수 최적화 위험: 지나치게 최적화 된 변수는 전략의 실패로 이어질 수 있다. 권장 조치: 샘플링 테스트를 사용하여 변수 안정성을 보장하십시오.
트렌드 확인 메커니즘: 트렌드 강도 지표 (ADX, MACD 등) 를 도입하여 트렌드 판단의 정확성을 높이는 것이 좋습니다.
동적 변수 조정: 시장의 변동에 따라 자동으로 EMA 주기 및 스톱 손실 변수를 조정할 수 있습니다.
포지션 관리 최적화: 변동율에 기반한 동적 포지션 관리 시스템을 도입한다.
다주기 협동: 더 긴 주기의 추세 판단과 결합하여 거래 방향의 정확도를 높인다.
이 전략은 EMA 트렌드 추적과 동적 스톱 손실 관리를 결합하여 완전한 거래 시스템을 구축한다. 전략의 핵심 장점은 명확한 거래 논리와 완벽한 위험 제어 장치에 있다. 제안된 최적화 방향을 통해 전략의 안정성과 수익성이 더욱 향상될 것으로 전망된다. 전략은 안정적인 수익을 추구하는 중장기 투자자에게 적합하다.
/*backtest
start: 2024-10-01 00:00:00
end: 2025-02-18 08:00:00
period: 2d
basePeriod: 2d
exchanges: [{"eid":"Binance","currency":"BTC_USDT"}]
*/
//@version=5
strategy("EMA 68 with Trailing Stop-Loss", overlay=true)
// Inputs for customization
length_ema = input(68, title="EMA Length")
initial_stop_loss_points = input(20, title="Initial Stop Loss in Points")
trail_distance = input(10, title="Trailing Stop Adjustment in Points")
ema68 = ta.ema(close, length_ema)
// Plot EMA
plot(ema68, color=color.blue, title="68-Day EMA")
var float entry_price = na // Store entry price
var bool is_long = false // Track if we are in a long trade
var bool is_short = false // Track if we are in a short trade
// Buy Condition: Close above 68-day EMA
if ta.crossover(close, ema68)
strategy.entry("Long", strategy.long)
entry_price := close
is_long := true
is_short := false
// Sell Condition: Close below 68-day EMA
if ta.crossunder(close, ema68)
strategy.entry("Short", strategy.short)
entry_price := close
is_long := false
is_short := true
// Long Exit Conditions
if is_long
stop_loss = entry_price - initial_stop_loss_points
trail_price = entry_price + initial_stop_loss_points
if close >= trail_price
stop_loss := entry_price + trail_distance
strategy.exit("LongExit", "Long", stop=stop_loss, when=close < ema68)
// Short Exit Conditions
if is_short
stop_loss = entry_price + initial_stop_loss_points
trail_price = entry_price - initial_stop_loss_points
if close <= trail_price
stop_loss := entry_price - trail_distance
strategy.exit("ShortExit", "Short", stop=stop_loss, when=close > ema68)