mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-26 08:45:16 +00:00
xmaker: use margin order to hedge positions
This commit is contained in:
parent
c2679b4ae1
commit
9f510da78b
|
@ -577,6 +577,7 @@ func (s *Strategy) Hedge(ctx context.Context, pos fixedpoint.Value) {
|
||||||
Type: types.OrderTypeMarket,
|
Type: types.OrderTypeMarket,
|
||||||
Side: side,
|
Side: side,
|
||||||
Quantity: quantity,
|
Quantity: quantity,
|
||||||
|
MarginSideEffect: types.SideEffectTypeMarginBuy,
|
||||||
})
|
})
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user