
이 전략은 수동 구매 및 판매 경보 도구로, 구매 가격, 판매 가격 등의 매개 변수를 설정할 수 있으며, 가격이 조건을 유발할 때 구매 또는 판매 경보를 상기시킨다.
이 전략은 자동화되지 않은 수동 구매/판매 도구입니다. 사용자가 미리 설정된 가격에서 구매/판매할 수 있도록 알람 을 생성할 수 있습니다. 사용자는 다음을 설정할 수 있습니다:
주기값과 설정값을 변경하여 이 전략을 쉽게 테스트할 수 있다.
이 방식은 사용자가 알림 정보를 기반으로 수동으로 거래 시간을 결정할 수 있고, 자동으로 주문할 필요가 없으며, 더 유연하다.
위험을 줄이기 위해 손실을 제한하기 위해 스톱을 사용하는 것이 좋습니다. 중요한 순간에 시장을 면밀히 관찰하고 제 시간에 행동하십시오. 여러 차례의 테스트를 진행하고 매개 변수를 최적화하십시오.
이러한 최적화를 통해, 이 도구는 사용자 친화적이고 지능적이 될 수 있으며, 수동 거래의 효율성을 높일 수 있습니다.
이 전략은 수동 거래의 보조 도구로서, 작동의 유연성이 가장 큰 장점이며, 거래의 시간을 전적으로 사용자의 판단에 따라 결정할 수 있습니다. 자동 거래 전략에 비해 더 많은 통제력을 가지고 있습니다. 동시에, 또한 파라미터를 설정 기능을 제공하여, 사용자가 다른 거래 전략을 테스트하고 거래 아이디어를 검증 할 수 있습니다. 물론, 도구로서, 사용자가 지속적으로 최적화하고 개선해야 할 필요가 있으므로, 더 복잡한 거래 요구에 적응 할 수 있습니다.
/*backtest
start: 2024-01-21 00:00:00
end: 2024-02-20 00:00:00
period: 1h
basePeriod: 15m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © MGTG
title_name = 'Manual Buy & Sell Alerts'
//@version=5
strategy(
title=title_name, overlay=true, initial_capital=10000, default_qty_type=strategy.percent_of_equity, default_qty_value=100,
pyramiding=1, commission_type=strategy.commission.percent, commission_value=0.1)
// Period
sTime = input(timestamp("2020-01-01"), "Start", group="Period", inline='1')
eTime = input(timestamp("2030-01-01"), "End", group="Period", inline='2')
inDateRange = true
// Bot Set-up
buy_type = input.string('stop', 'Buy Type', group='Buy&Sell', inline='1', options=['stop', 'limit'])
buy_price = input.float(49000, 'Buy Price', group='Buy&Sell', inline='1')
target_price = input.float(51000, 'Target Price', group='Buy&Sell', inline='2')
stop_price = input.float(47000, 'Stop Price', group='Buy&Sell', inline='2')
avg_price = strategy.position_avg_price
division = 1
// Alert message
AlertLong=input.string("Buy message", "Buy Alert Message", group='Alert set-up', inline='1')
AlertExit=input.string("Sell message", "Sell Alert Message", group='Alert set-up', inline='1')
plot(buy_price, 'Buy Price', color=color.new(#009688, 0), style=plot.style_linebr, offset=1)
plot(target_price, 'Take Profit', color=color.new(color.orange, 0), style=plot.style_linebr, offset=1)
plot(stop_price, 'Safety', color=color.new(color.aqua, 0), style=plot.style_linebr, offset=1)
posSize =
strategy.equity / close
strategy.exit("sell", "buy", limit=target_price, stop=stop_price, alert_message=AlertExit)
longCondition = inDateRange and strategy.position_size == 0
if longCondition and buy_type == 'stop'
strategy.entry("buy", strategy.long, qty=posSize, stop=buy_price, when=close < buy_price, comment="buy_STOP", alert_message=AlertLong)
if longCondition and buy_type == 'limit'
strategy.entry("buy", strategy.long, qty=posSize, limit=buy_price, when=close > buy_price, comment="buy_LIMIT", alert_message=AlertLong)