mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-25 16:25:16 +00:00
liqmaker: add more logs to the liq order generator
This commit is contained in:
parent
2b0e4e0512
commit
dbd53429cd
|
@ -46,6 +46,14 @@ func (g *LiquidityOrderGenerator) Generate(
|
|||
g.logger = logger
|
||||
}
|
||||
|
||||
g.logger.Infof("generating %s orders with total amount %s from price %s to price %s with %d layers",
|
||||
side,
|
||||
totalAmount.String(),
|
||||
startPrice.String(),
|
||||
endPrice.String(),
|
||||
numLayers,
|
||||
)
|
||||
|
||||
layerSpread := endPrice.Sub(startPrice).Div(fixedpoint.NewFromInt(int64(numLayers - 1)))
|
||||
switch side {
|
||||
case types.SideTypeSell:
|
||||
|
@ -59,6 +67,8 @@ func (g *LiquidityOrderGenerator) Generate(
|
|||
}
|
||||
}
|
||||
|
||||
g.logger.Infof("side %s layer spread: %s", side, layerSpread.String())
|
||||
|
||||
quantityBase := 0.0
|
||||
var layerPrices []fixedpoint.Value
|
||||
var layerScales []float64
|
||||
|
|
Loading…
Reference in New Issue
Block a user