Skip to content

Commit 15879ad

Browse files
committed
pivotshort: fix trade loss ratio
1 parent 88c0f31 commit 15879ad

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/strategy/pivotshort/breaklow.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ func useQuantityOrBaseBalance(session *bbgo.ExchangeSession, market types.Market
262262
accountValue := baseBalanceValue.Add(quoteBalance.Net())
263263

264264
// avoid using all account value since there will be some trade loss for interests and the fee
265-
accountValue = accountValue.Mul(one.Sub(fixedpoint.NewFromFloat(0.9)))
265+
accountValue = accountValue.Mul(one.Sub(fixedpoint.NewFromFloat(0.01)))
266266

267267
log.Infof("calculated account value %f %s", accountValue.Float64(), market.QuoteCurrency)
268268

0 commit comments

Comments
 (0)