Intraday Position average price calculations

Hello Team,

Similar to the clarification query requested for the holding price for delivery

But now in case of intraday

Buy 10 @ 100
Buy 10 @ 90
Buy 10 @ 80
Sell 10 @ 95

Ofcourse all of these will.be shown in position section

Q1 : does it get calculated as below based on weighted avg price and NOT FIFO

= overall buy postion as tot buy > tot sell
= Total buy amt - total sell amt / tot qty
( 100 × 10 + 10 x 90 + 10 x 80 ) - ( 10 x 95 ) / 20
= ( 2700 - 950 ) / 20
= 87.5

Postion avg price = 87.5 with qty = 20

Q2: ofcourse in case of the PNL when everything is sold off

Final PnL = Total sell - total buy - buy and sell charges

Regards,
Kartik

When you sell 1 quantity, the system calculates profit or loss in the backend using FIFO.However, in the positions tab the average buy price does not change.
The average price only changes when you buy more quantities, not when you sell.

Yes thats correct.

1 Like

@Swapneel_Dey

Just clarifying , so after all buy the avg price is 90 with qty 30

So when the sell happens the avg price remains the same as 90 but the qty is now reduced to 20 ( since 10.is sold )

Pls let know if my understanding is correct.

@mnkartik Yes thats correct.

1 Like

I have another scenario @Swapneel_Dey

If below are the txs where the last sell made it as SHORT position with qty10

Buy 10 @ 100
Buy 10 @ 90
Buy 10 @ 80
Sell 10 @ 95
Sell 10 @ 98
Sell 20 @ 105

Q: how is the avg price calculated

Q: how does fifo is applied to this. First two sells are clear but how abt the last sell where the qty is 20. Because now this being a short position how is the fifio applied