Where has the profit gone?


The bot brags about $410 profit but still “current balance” declines in both base and quote.

What market and trading direction and bot is that?

I believe it might have been my fault. I exported a bot that have been running for weeks and imported it to another user without noticing that “take profit” had been changed from quote to base somewhere on the way.

My original question does however stand. Where did the profit go? if profit was supposed to be taken in base, how come current base balance went down from 8858 to 8840 when it should have increased with 164 SUI?

The spot trading bot is running a long strategy.

What’s your current uPnL? Are the unrealized losses bigger than you profits? Do you run “short” spot?

“The spot trading bot is running a long strategy.”
I’ll check the P/L in a minute
I’m logged in as a different user right now.

Thank you for making me think, but can there be an unrealized loss when the bot only is allowed to have one open deal, have a minimum take Profit of 2% and the deal is closed?

Are there any assets in the account that can lose in value?

How would that change anything?

Here comes the answer to my own question (but on a new deal):


What you see above is the documentation from one (out of many) deals. It was opened 2025-04-07 at 15.26, and closed 2025-04-07 at 21.42. During this time the price of this coin decreased (Drawdown) with 4,44% and increaded (Run Up) with 1,84% (1,84 - 4,44 = -2,6). That is what happened between the starting price of 2,0417 USDC and the closing price of 2,0794 USDC (a difference of 1,85%). 94% of the time the deal was opened it was in loss (the price was lower than the entry price) and still the bot managed to squeeze out a profit of 1,65% = $110,12.
The next deal was opened 28 minutes later at 22.10 when the price was 2,057 which equals a Drawdown of 2,2%. This means that between the start of the top deal and the start of the second deal (which by the way brought in 1,51%) your fortune decreased by 2,24%, even though the bot made a profit of 1,65% during the same time. Bots can’t work on every price wave (and if you try you will lose big time).

I don’t understand your calculations. Why did you sum drawdown and run up? 1.85 - 2 * 0.1 (fees) = 1.65. And what’s the point of the second paragraph?

It is to show that the bot did catch most of the run-up (1.65% of the 1.85%) but this gain was eaten up by the larger drawdown during the time the deal was open. i.e. the bot made a profit even though the portfolio suffered a loss during the time the deal was open.

To show that this was not just a single occasion I pointed out that also the next deal did the same thing. The Bot then made a profit of 1.51% but since the drawdown was 2.2% the portfolio suffered a loss even though the bot made a profit and how that could be was my initial question which I did not get an answer to from the community.

When I increased the minimum Take Profit the problem disappeared.