Hello, How can I get the number of shares that would be bought on a given signal in low level CBT?
I use the formula : NbShares=-ceil(sig.PosSize*CurEquity/100/sig.price/sig.RoundLotSize) *sig.RoundLotSize; I don't get the exact number of shares bought or sold by AB. As an exemple, with: CurEquity=500000 PosSize=-5 sig.Price=22.86 sig.RoundLotSize=100 my formua gives NbShares=1000. The exact value is 1093 rounded to 1000. The signal processed trades 1100 shares. The position value for 1100 shares is 25113 that is above the 5% equity limit given by PosSize (25000=5% * 500000). Amibroker default calculation seems incorrect. WHat is the formula used by AB? Regards, Olivier
