update config structure

This commit is contained in:
c9s 2022-06-26 19:20:08 +08:00
parent 3604bae933
commit 279bb66a4d
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54
3 changed files with 62 additions and 42 deletions

View File

@ -60,34 +60,32 @@ exchangeStrategies:
numOfLayers: 1 numOfLayers: 1
layerSpread: 0.1% layerSpread: 0.1%
exit: exits:
# roiStopLossPercentage is the stop loss percentage of the position ROI (currently the price change) # roiStopLoss is the stop loss percentage of the position ROI (currently the price change)
roiStopLossPercentage: 2% - roiStopLoss:
percentage: 2%
# roiTakeProfitPercentage is used to force taking profit by percentage of the position ROI (currently the price change) # roiTakeProfit is used to force taking profit by percentage of the position ROI (currently the price change)
# force to take the profit ROI exceeded the percentage. # force to take the profit ROI exceeded the percentage.
roiTakeProfitPercentage: 30% - roiTakeProfit:
percentage: 30%
# roiMinTakeProfitPercentage applies to lowerShadowRatio and cumulatedVolume exit options - protectionStopLoss:
roiMinTakeProfitPercentage: 10%
roiProtectionStopLoss:
activationRatio: 1% activationRatio: 1%
stopLossRatio: 0.2% stopLossRatio: 0.2%
placeStopOrder: true
# lowerShadowRatio is used to taking profit when the (lower shadow height / low price) > lowerShadowRatio # lowerShadowTakeProfit is used to taking profit when the (lower shadow height / low price) > lowerShadowRatio
# you can grab a simple stats by the following SQL: # you can grab a simple stats by the following SQL:
# SELECT ((close - low) / close) AS shadow_ratio FROM binance_klines WHERE symbol = 'ETHUSDT' AND `interval` = '5m' AND start_time > '2022-01-01' ORDER BY shadow_ratio DESC LIMIT 20; # SELECT ((close - low) / close) AS shadow_ratio FROM binance_klines WHERE symbol = 'ETHUSDT' AND `interval` = '5m' AND start_time > '2022-01-01' ORDER BY shadow_ratio DESC LIMIT 20;
lowerShadowRatio: 3% - lowerShadowTakeProfit:
ratio: 3%
# cumulatedVolume is used to take profit when the cumulated quote volume from the klines exceeded a threshold # cumulatedVolumeTakeProfit is used to take profit when the cumulated quote volume from the klines exceeded a threshold
cumulatedVolume: - cumulatedVolumeTakeProfit:
enabled: true
minQuoteVolume: 90_000_000 minQuoteVolume: 90_000_000
window: 5 window: 5
marginOrderSideEffect: repay
backtest: backtest:
sessions: sessions:
- binance - binance

View File

@ -22,11 +22,31 @@ exchangeStrategies:
numLayers: 3 numLayers: 3
marginOrderSideEffect: borrow marginOrderSideEffect: borrow
exit: exits:
takeProfitPercentage: 13% # roiStopLoss is the stop loss percentage of the position ROI (currently the price change)
stopLossPercentage: 0.5% - roiStopLoss:
shadowTakeProfitRatio: 3% percentage: 2%
marginOrderSideEffect: repay
# roiTakeProfit is used to force taking profit by percentage of the position ROI (currently the price change)
# force to take the profit ROI exceeded the percentage.
- roiTakeProfit:
percentage: 30%
- protectionStopLoss:
activationRatio: 1%
stopLossRatio: 0.2%
placeStopOrder: true
# lowerShadowTakeProfit is used to taking profit when the (lower shadow height / low price) > lowerShadowRatio
# you can grab a simple stats by the following SQL:
# SELECT ((close - low) / close) AS shadow_ratio FROM binance_klines WHERE symbol = 'ETHUSDT' AND `interval` = '5m' AND start_time > '2022-01-01' ORDER BY shadow_ratio DESC LIMIT 20;
- lowerShadowTakeProfit:
ratio: 3%
# cumulatedVolumeTakeProfit is used to take profit when the cumulated quote volume from the klines exceeded a threshold
- cumulatedVolumeTakeProfit:
minQuoteVolume: 90_000_000
window: 5
backtest: backtest:

View File

@ -25,31 +25,33 @@ exchangeStrategies:
interval: 1h interval: 1h
window: 99 window: 99
exit: exits:
# roiStopLossPercentage is the stop loss percentage of the position ROI (currently the price change) # roiStopLoss is the stop loss percentage of the position ROI (currently the price change)
roiStopLossPercentage: 1% - roiStopLoss:
percentage: 2%
# roiTakeProfitPercentage is the take profit percentage of the position ROI (currently the price change) # roiTakeProfit is used to force taking profit by percentage of the position ROI (currently the price change)
# force to take the profit ROI exceeded the percentage. # force to take the profit ROI exceeded the percentage.
roiTakeProfitPercentage: 25% - roiTakeProfit:
percentage: 30%
# roiMinTakeProfitPercentage applies to lowerShadowRatio and cumulatedVolume exit options - protectionStopLoss:
roiMinTakeProfitPercentage: 10% activationRatio: 1%
stopLossRatio: 0.2%
placeStopOrder: true
# lowerShadowRatio is used to force taking profit when the (lower shadow height / low price) > lowerShadowRatio # lowerShadowTakeProfit is used to taking profit when the (lower shadow height / low price) > lowerShadowRatio
# you can grab a simple stats by the following SQL: # you can grab a simple stats by the following SQL:
# SELECT ((close - low) / close) AS shadow_ratio FROM binance_klines WHERE symbol = 'ETHUSDT' AND `interval` = '5m' AND start_time > '2022-01-01' ORDER BY shadow_ratio DESC LIMIT 20; #
lowerShadowRatio: 3% # SELECT ((close - low) / close) AS shadow_ratio FROM binance_klines WHERE symbol = 'ETHUSDT' AND `interval` = '5m' AND start_time > '2022-01-01' ORDER BY shadow_ratio DESC LIMIT 20;
- lowerShadowTakeProfit:
ratio: 3%
# cumulatedVolume is used to take profit when the cumulated quote volume from the klines exceeded a threshold # cumulatedVolumeTakeProfit is used to take profit when the cumulated quote volume from the klines exceeded a threshold
cumulatedVolume: - cumulatedVolumeTakeProfit:
enabled: false
minQuoteVolume: 90_000_000 minQuoteVolume: 90_000_000
window: 5 window: 5
marginOrderSideEffect: repay
backtest: backtest:
sessions: sessions:
- binance - binance