The script should use a screener to collect stocks that have more than 1M volume and are up at least 10% from the previous day's close. it should sort the stocks based on short-term 3-minute volume (highest to lowest). Once the list is gathered it should pull the top results, such as 5, which will then be used to run the strategy against. The screener should be checked occasionally, such as every 5min, and the new list of stocks should be used.

historical data for the list of stocks should be pulled. perhaps the last 30 1-minute candles.

i also want to receive live stream data in 1min segments. as new data comes in from the live stream, the oldest data in the historical set should be dropped out.

based on the info from the candles, highs and lows are set. highs are set once the following 3 bars are confirmed to be a lower price than the high bar. vice versa for setting the low.

Once the current 1-minute candle closes above the highest high, a limit buy order should be placed. The quantity of the buy order should be determined as an integer based on the amount of cash in my account (for example, 10% of cash), and I would not want to be in more than 2 trades at a time.

a take profit limit order (set at a percentage of the limit buy price, such as 1.03 of the buy price) should be placed.

A stop loss limit order should be placed at the midpoint of the "box", with the initial stop loss trigger set at this point and the limit set about 1.5% less.

All orders should be canceled if the buy is not filled within 45 seconds

If any of this seems over complicated/too difficult, let me know and perhaps we can simplify. i'd prefer for this to be for Alpaca, but Interactive Brokers is ok.

Budget: $350
Posted On: April 07, 2023 02:09 UTC
Category: Scripting & Automation
Skills:Python, API Integration, Trading Automation, Trading Strategy, Algorithm Development, Risk Management
Country: United States
click to apply