add backtest config

This commit is contained in:
narumi 2023-10-11 12:12:57 +08:00
parent d8ff42d531
commit 4a6f6f7a5a
2 changed files with 21 additions and 4 deletions

View File

@ -1,10 +1,27 @@
---
backtest:
startTime: "2023-01-01"
endTime: "2023-05-31"
symbols:
- USDCUSDT
sessions:
- max
accounts:
max:
balances:
USDC: 500.0
USDT: 500.0
exchangeStrategies:
- on: max
fixedmaker:
symbol: BTCUSDT
symbol: USDCUSDT
interval: 5m
halfSpread: 0.05%
quantity: 0.005
quantity: 15
orderType: LIMIT_MAKER
dryRun: true
dryRun: false
positionHardLimit: 1500
maxPositionQuantity: 1500
circuitBreakLossThreshold: -0.15

View File

@ -64,7 +64,7 @@ func (s *Strategy) Validate() error {
}
if s.HalfSpread.Float64() <= 0 {
return fmt.Errorf("halfSpreadRatio should be positive")
return fmt.Errorf("halfSpread should be positive")
}
return nil
}