PositionSizer icon indicating copy to clipboard operation
PositionSizer copied to clipboard

Incorrect commission calculation?

Open pxsanghyo opened this issue 9 months ago • 10 comments

I've seen the other similar closed issues and I understand that those were indeed correct but the results I'm getting is seem different.

Image

In the screenshot above, when UseCommissionToSetTP = true, commission = $8.25

  1. Why is Risk, USD Input = Results? It seems like it's ignoring commission.
  2. Reward, USD Input seem high, shouldn't it be commission + result?

Please correct me if I'm wrong, I love your EA.

pxsanghyo avatar Mar 13 '25 08:03 pxsanghyo

First of all, thanks for having checked previous closed issues on this topic!

As for this case, the idea is that if you leave the TP line where it is now and then remove the commission, the position size will also increase, resulting in an even higher potential reward.

EarnForex avatar Mar 13 '25 08:03 EarnForex

Sorry, you're probably right but I'm just looking for clarification.

If my calculation is correct, Risk should be 101.33 - 8.25 = 93.08 and Reward should be 101.33*2 + 8.25 = 210.91

Am I wrong?

pxsanghyo avatar Mar 13 '25 09:03 pxsanghyo

No, the risk stays the same in the left column because it's just % x Balance. And the reward stays the same there because it's basically (TP distance / SL distance) * Risk.

EarnForex avatar Mar 13 '25 09:03 EarnForex

Ok, I think I get it.

Is it possible to change risk value to include commission. So that when it hits stop loss, the total loss (including commission) equals the risk %?

pxsanghyo avatar Mar 13 '25 09:03 pxsanghyo

But it already does include that. If you lose that trade, you lose 101.14 as is written in the Risk Result column.

EarnForex avatar Mar 13 '25 10:03 EarnForex

Currently if you lose that trade you lose 101.14, but you also lose 8.25 commission, so 101.14+8.25 is more than 1% of account. Sorry if I wasn't clear on that, hopefully that was better.

pxsanghyo avatar Mar 13 '25 10:03 pxsanghyo

Are you sure? Could you please show an example of that?

EarnForex avatar Mar 13 '25 11:03 EarnForex

OH! okay, so the results column is not the "final" value when you enter trade? I just entered a demo trade and the amount at SL and TP is very close to what I thought it should be, which is

SL = (Risk, USD Results) - Commission TP = (Reward, USD Results) + Commission

I guess it's not exact because of lot step size.

pxsanghyo avatar Mar 13 '25 11:03 pxsanghyo

The Results column is the final value. There should only be minor differences due to rounding or currency rate changes (when profit currency is different from the account currency).

EarnForex avatar Mar 13 '25 11:03 EarnForex

To be honest, I'm still confused but I appreciate your time and effort so I'm going to leave it here.

Can I request a feature? Right now, you can input "TP Multiplier for SL Value" but it'd be nice if there was a TP Multiplier text field on the interface so you can change it on the fly.

Thanks!

pxsanghyo avatar Mar 13 '25 12:03 pxsanghyo