Buy\Sell Difference mania

From what I understand, Buy/Sell Difference is caused by both buy and sell rules applying at the same time.

I seem to get a lot of these clustered together which tells me my sell rules need to change.
I suspect this is what happens when sell rules are unrelated to Rank.

Any suggestions?



buy-sell_rule.PNG

Setting “Allow Immediate Buyback” on the Rebalance tab to ‘No’ will reduce the occurrences of this. But to eliminate it, you would need some Buy rule that contradicts a sell rule. For example, you have the sell rule SI%ShsOut > 4. So adding a buy rule of SI%ShsOut < 4 would eliminate the buyback since SI%ShsOut cant be true for both the buy and sell rule. But if the SI%ShsOut is hovering around 4, you could get cases where it is sold and then bought back a week later.

There is also a function LastSellDaysLT that prevents buybacks in the specified timeframe.
Ex: to avoid buying a stock that was sold within the last 30 days, enter the following Buy rule: LastSellDaysLT(30)=FALSE