fastquant icon indicating copy to clipboard operation
fastquant copied to clipboard

Rework on combining multiple strategies.

Open jbdelmundo opened this issue 4 years ago • 0 comments

Description: The combination could be as

  1. Diversified Strategy: works for diversifying strategies
  2. Combine signals under 1 strategy

Detailed example: Assume that different signals for Strategy 1 and Strategy 2 occurs on the following timestamps

Timestamp Strategy 1 Strategy 2 Diversified Strategy Combined signal OR Combined signal AND
1 BUY BUY1 BUY
2
3 BUY BUY2
4 SELL SELL1 SELL
5 SELL SELL2
6 BUY BUY BUY 1&2 BUY BUY
7
8 SELL SELL SELL 1&2 SELL SELL
9

For Diversified Strategy:

  • It works as if the two strategies are implemented at the same time.
  • Note that it allows consecutive Buy Signals at timestamp 1 and 3 (from Strat 1 and Strat 2 respectively)
  • It might require additional parameter such as position_size to allow consecutive buy signals and sell signals
  • This assumes that there are 2 different strategies that triggers the 2 trades

For Combined Signal OR

  • The buy or sell signal is generated if ANY of the signals of the strategies are sent
  • Unlike the Diversified Strategy it would not allow consecutive buy and sell signals

For Combined Signal AND

  • The buy or sell signal is generated if ALL of the signals of the strategies are sent

jbdelmundo avatar Feb 02 '21 09:02 jbdelmundo