Skip to content

Commit

Permalink
loss_allowance_pct is weighted by total_wallet_exposure_limit
Browse files Browse the repository at this point in the history
  • Loading branch information
enarjord committed Sep 19, 2024
1 parent 666dc00 commit 2ed63a8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/passivbot.py
Original file line number Diff line number Diff line change
Expand Up @@ -1508,9 +1508,10 @@ def calc_unstucking_close(self, ideal_orders):
calc_AU_allowance(
np.array([x["pnl"] for x in self.pnls]),
self.balance,
loss_allowance_pct=self.live_configs[symbol][pside][
loss_allowance_pct=self.config["bot"][pside][
"unstuck_loss_allowance_pct"
],
]
* self.config["bot"][pside]["total_wallet_exposure_limit"],
)
if len(self.pnls) > 0
else 0.0
Expand Down

0 comments on commit 2ed63a8

Please sign in to comment.