
이 전략은 1.5%의 위험 통제를 적용하고 수익을 증대하기 위해 레버리지를 결합합니다. 이 전략의 핵심은 여러 기술적 지표의 조합을 통해 트렌드를 확인하는 것과 동시에 동적 스톱 손실을 사용하여 자금을 보호하는 것입니다. 전략 설계는 소규모 자본 계좌의 특성을 충분히 고려하여 신속하고 빈번한 거래에 적합합니다.
이 전략은 세 가지 주요 기술 지표를 사용한다: RSI ((상대적으로 강한 지표), EMA ((지수 이동 평균) 및 ATR ((평균 실제 파도) ᅳ 입문 신호는 단기 EMA ((9주기) 와 장기 EMA ((21주기) 의 교차 확인을 받으며, 동시에 RSI가 합리적인 범위 내에서 요구된다 ((다중 RSI <70, 공수 RSI> ᅳ30) 이 전략은 ATR 기반의 동적 중지 손실 방식을 채택하고, 중지 위치는 손실의 4배입니다. 이 설정은 수익을 보장하면서 위험을 제어 할 수 있습니다.
이것은 합리적인 트렌드 추적 전략을 설계하여 여러 기술 지표의 조합을 통해 거래의 성공률을 높입니다. 전략의 위험 제어 메커니즘은 완벽하며 소액 계좌에 적합합니다. 그러나 실물 거래에서는 시장 환경의 변화에 주의를 기울이고 다른 시장 상태에 적응하기 위해 적절한 시기에 매개 변수를 조정해야합니다. 실물 이전에 충분한 재검토를 수행하고 작은 위치 아래 전략 특성을 단계적으로 적용하는 것이 좋습니다.
/*backtest
start: 2019-12-23 08:00:00
end: 2024-12-04 00:00:00
period: 1d
basePeriod: 1d
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=5
strategy("Aggressive Scalper Strategy", overlay=true)
// Parameters
account_balance = input.float(28.37, title="Account Balance", tooltip="Update this with your balance")
risk_per_trade = input.float(0.015, title="Risk per Trade", tooltip="1.5% risk")
leverage = input.int(2, title="Leverage", minval=1)
stop_loss_percentage = input.float(0.015, title="Stop Loss Percentage", tooltip="1.5% stop loss")
take_profit_multiplier = input.float(4, title="Take Profit Multiplier", tooltip="Take Profit is 4x Stop Loss")
stop_loss_multiplier = input.float(2, title="Stop Loss Multiplier", tooltip="Dynamic Stop Loss Multiplier")
// Trade Size Calculation
position_size = account_balance * risk_per_trade / (stop_loss_percentage / leverage)
trade_qty = position_size / close // This gives you the qty in terms of contracts
// Indicators
rsiLength = input.int(14, title="RSI Length")
emaShort = input.int(9, title="Short-term EMA Length")
emaLong = input.int(21, title="Long-term EMA Length")
rsi = ta.rsi(close, rsiLength)
emaShortLine = ta.ema(close, emaShort)
emaLongLine = ta.ema(close, emaLong)
// Entry Conditions
longCondition = ta.crossover(emaShortLine, emaLongLine) and rsi < 70
shortCondition = ta.crossunder(emaShortLine, emaLongLine) and rsi > 30
// ATR for dynamic stop loss and take profit levels
atrLength = input.int(14, title="ATR Length")
atrMultiplier = input.float(1.5, title="ATR Multiplier")
atr = ta.atr(atrLength)
// Dynamic Take Profit and Stop Loss Levels
longTakeProfitLevel = close + (atr * take_profit_multiplier)
longStopLossLevel = close - (atr * stop_loss_multiplier)
shortTakeProfitLevel = close - (atr * take_profit_multiplier)
shortStopLossLevel = close + (atr * stop_loss_multiplier)
// Strategy Execution
if (longCondition)
strategy.entry("Long", strategy.long, qty=trade_qty)
strategy.exit("Take Profit/Stop Loss", from_entry="Long", limit=longTakeProfitLevel, stop=longStopLossLevel)
if (shortCondition)
strategy.entry("Short", strategy.short, qty=trade_qty)
strategy.exit("Take Profit/Stop Loss", from_entry="Short", limit=shortTakeProfitLevel, stop=shortStopLossLevel)
// Alert Conditions
alertcondition(longCondition, title="Buy Signal", message="Long position entry signal detected.")
alertcondition(shortCondition, title="Sell Signal", message="Short position entry signal detected.")
// Display Information on Chart
var table_info = table.new(position.top_right, 2, 2, frame_color=color.blue, frame_width=1)
if (bar_index == na)
table.cell(table_info, 0, 0, text="Aggressive Scalper", bgcolor=color.blue)
table.cell(table_info, 1, 0, text="Account Balance: $" + str.tostring(account_balance), text_color=color.white)
table.cell(table_info, 1, 1, text="Risk per Trade: " + str.tostring(risk_per_trade * 100) + "%", text_color=color.white)
table.cell(table_info, 0, 1, text="Leverage: " + str.tostring(leverage) + "x", text_color=color.white)