What are the MoonHook strategy specific parameters?

: Strategy settings

Specific parameters of the MoonHook strategy:

BuyOrderReduce: sets the interval (in ms) used to calculate the average trade volume. The strategy will place an order of size not larger than the average volume. By default = 100ms. Volume calculation: sum of all trades (buy and sell) over the TimeInterval interval, divided by BuyOrderReduce. Examlple: if TimeInterval = 5 sec (5000 ms), BuyOrderReduce = 100ms, the volume over 5 sec was 10 000$, the average volume over 100ms will equal 10000/5000ms*100ms=200$. In this case the strategy will place an order not larger than 200$.Alternatively, knowing the average volume over 100 / 10/ 5 ms, this will be the maximum order size of the strategyBuyOrderReduce=0 – parameter is turned offThe work of the order reduction function can be seen in the following inscription:IOTA: [1] (40) Buy order reduced: 1000.00$ => 23.32$ (Vol: 23.32$)In this log, the OrderSize in the strategy was 1000$, but the average volume over 100ms was just 23$, thus, the strategy has placed an order of 23$.

MinReducedSize: If after using BuyOrderReduce the order size becomes lower than the set size (in USDT), the order is not placed (and the corresponding detect will not exist). Default value = 0(not applied).

HookTimeFrame: time frame set for analysis.

HookDetectDepth: the depth of the detect.

HookDetectDepthMax: the maximum detect depth value for a shot. If 0, is ignored.

HookAntiPump: If YES, the average price before the detection is taken to calculate the depth of detection, which allows to exclude shoots right after a fast growth. In existing strategies the HookAntiPump parameter is enabled by default, with this parameter the work of the strategy is closer to what it was before the update.

HookPriceRollBack: percentage of price roll back in percentage points relative to the general depth, 33% would mean a roll back by one third of the entire price movement

HookPriceRollBackMax: The rollback limit is no more than. If 0 (default), has no effect.

HookRollBackWait: The time during which the price stays above the RollBack (milliseconds). The recommended value of 100ms will cut off situations when the price immediately drops after detection. You can set more, but the entire event of a spike, rollback and waiting for a rollback must keep within the HookTimeFrame sec.

HookDropMin, HookDropMax: price decrease prior to the detect over the last 2 minutes, before and after. Is calculated in percentage points relative to the recorded depth of the shot.

Example: Take a 10% shot. But the price of the coin has allready been falling for 2 minutes before the shot and has already fallen by 20%.

In this case, the HookDrop = 20 / 10 * 100 = 200% (i.e the previous decrease in price is 200% larger than the shot itself). If 0, is ignored.

HookDirection: search for Long or Short detects or both.

HookOppositeOrder: place an order in the opposite direction (when an arrow is detected, put a short instead of a long)

HookInterpolate:
– If 0, the strategy will place an order from the uppermost price to the shot.
– If 1, the strategy will place an order from the rollback following the shot
– If 2, the HookInitialPrice parameter will be prioritized
– If 3, calculates the initial price and the corridor from current price, based on spike depth
– If 4, is based on rollback depth

If it contradicts the price range, the upper limit of the range will be moved up by half the distance between your order and the current price. If this is impossible, the detect will not execute.

Applying the same logic, the lower limit will be lowered.

The logic is the same for both short and long orders.

HookPriceDistance: the width of the price range. Set in percentage points relative to the general detect depth. For example: if a 5% fall was detected, a HookPriceDistance = 10% will mean that the order can move within the following limits — upper limit HookPriceDistance = 5-5/100*10=4,5%, lower limit 5+5/100*10=5,5% from the current price. Just like the MoonShot, it will be moved when the price will come close to one of the limits. If 0, the order is not move like in case of MoonShot, will remain static until execution or cancellation.

HookPartFilledDelay: Delay for canceling a buy order after partial filling (milliseconds). If 0, there is no delay, the partially filled order is immediately canceled (as in moonshots)

HookSellLevel: replaces SellPrice. Is set in percent of the detect depth.

For example: SellPrice = 75% would mean that it should sell in the upper quarter of the shot. SellPrice = 100% would mean selling at the upmost point, at the start of the shot.

HookSellFixed: always calculate sell as (HookSellLevel * depth) percent, regardless of the buy price

HookReplaceDelay: Delay to replace the buy upon price drops

HookRaiseWait: Delay to replace the buy upon price raise

HookRepeatAfterSell: repeat buy order after the sell is executed

HookRepeatIfProfit: %, repeat if the sale closed with such or a large profit.

BuyOrderReduce: (the parameter has migrated from the Spread strategy and has similar values). Sets a time frame (in ms) for which the average tradin vaolume is calculated. The strategy will then place an order not larger than the average volume. Default value = 100 (ms). Volume is calculated as follows: all trades volume is sumed up (buy and sell) for the HookTimeFrame period and is devided by BuyOrderReduce.

For example: if HookTimeFrame = 5 sec (5000 ms), BuyOrderReduce = 100ms, the volume over 5 sec was 10000$, the average volume for 100ms will equal10000/5000ms*100ms=200$. In this case the strategy will place an order of no more than 200$.

In other words, we monitor the average volume over the last 100ms/10ms/5ms, that will be our maximum order size used by the strategy.

BuyOrderReduce=0 – parameter is turned off