简体   繁体   中英

Automated execution for pine-script strategy?

General question for any pine-script strategy.

For example from the documentation: https://www.tradingview.com/pine-script-docs/en/v4/essential/Strategies.html#a-simple-strategy-example

//@version=4
strategy("test")
if bar_index > 4000
    strategy.entry("buy", strategy.long, 10, when=strategy.position_size <= 0)
    strategy.entry("sell", strategy.short, 10, when=strategy.position_size > 0)
plot(strategy.equity)

Is it possible to have this strategy executed automatically at the indicated time through the TradingView platform?

This is for an equity strategy so I assume I'd have to have an equity supporting broker (TradeStation as opposed to OANDA or AMP) but even just automated paper trading execution?

Right now, I'm guessing that instead I might need to re-create my strategy through QuantConnect or Quantopian for that to work.

You can use alerts to send signals, and do whatever you please with the signals. They've improved the alerts functionality recently, so it's definitely doable.

  1. Develop your strategy and ensure it is sending alerts as intended.
  2. Find a broker with an API that you want to use.
  3. Rent a VPS to listen for webhooks.
  4. Code your response to the webhooks to trade on your broker.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM