Hi,
I am currently trying to work out how poloniex calculates fees and order quantities for buy orders when margin trading:
Below is an example and wondered if anyone was able to explain how they are calculated, needless to say I asked poloniex support months ago but still no response.
Below applies to any buy order weather to open a new position or to partially close an existing short, ultimately I need to be able to exactly calculate how much I can open of a new position or partially close of a long position to ensure I manage risk correctly.
let's say I am short 1 ETH at a price of 0.09785835 and I want to close the position (not using the close position function). If I place a buy order of 1 it does not fully cover the position, if I place a buy order of
1.00501882 @ 0.0998 I end up with a new long position of 0.00100243, implying a fill of 1.00100243 with 0.00401639 taken up in fees, but I can't figure out what. The fees should be 0.25% (assuming taker) which would mean fees of 0.00251254705 on the orignal order and a fill of 1.00250627295 (1.00501882-0.00251254705).
It seems that poloniex firstly takes 0.25% of the order you place, then applies the maker/taker fee to that, but even working it like this the number's don't add up 100% so either some rounding or going on or the trade price is a component in the fee.
What I believe happens is that only 99.75% of the 1.00501882 orders get's placed on the exchange (regardless of weather maker or taker), so in this case 1.00250627295 which is rounded down to 8DP, 1.00250627 is placed, which when filled the maker/taker fees are applied (0.0025062656750) rounded up to 8dp 0.00250627 leaving a fill of 1, which still leaves 0.00100243 unexplained.
Any insights would be welcomed, screen shots attached.