Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
buy_and_sell_strategies [2019/01/11 13:00]
armchairguru
buy_and_sell_strategies [2019/01/31 14:31] (current)
armchairguru
Line 8: Line 8:
  
 ^ Strategies ^     ​NORMAL BUY    ^    NORMAL SELL     ​^ ​     DCA BUY       ​^ ​ DCA SELL        ^    ^ Strategies ^     ​NORMAL BUY    ^    NORMAL SELL     ​^ ​     DCA BUY       ​^ ​ DCA SELL        ^   
-^ [[buy_and_sell_strategies#​LOWBB]] ​     |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | +^ [[buy_and_sell_strategies#​SIGNAL]] ​   |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  
 +^ [[buy_and_sell_strategies#​LOWBB]] ​    ​|  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | 
 ^ [[buy_and_sell_strategies#​HIGHBB]] ​   |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​HIGHBB]] ​   |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​GAIN]] ​       | |  {{glyphicon>​ok?​12}} ​ | |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​GAIN]] ​       | |  {{glyphicon>​ok?​12}} ​ | |  {{glyphicon>​ok?​12}} ​ |
Line 14: Line 15:
 ^ [[buy_and_sell_strategies#​SMAGAIN]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​SMAGAIN]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​EMAGAIN]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​EMAGAIN]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​HMAGAIN]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​DEMAGAIN]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​SMASPREAD]] |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​SMASPREAD]] |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​EMASPREAD]] |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​EMASPREAD]] |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​HMASPREAD]] |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​DEMASPREAD]] |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​SMACROSS]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​SMACROSS]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​EMACROSS]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​EMACROSS]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​HMACROSS]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​DEMACROSS]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​RSI]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​RSI]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​STOCH]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​STOCH]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
Line 27: Line 34:
 ^ [[buy_and_sell_strategies#​BBWIDTH]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​BBWIDTH]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​OBV]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ | ^ [[buy_and_sell_strategies#​OBV]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 +^ [[buy_and_sell_strategies#​PDHIGH]] ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |  {{glyphicon>​ok?​12}} ​ |
 ^ [[buy_and_sell_strategies#​ANDERSON]] ​ | | |  {{glyphicon>​ok?​12}} ​ | | ^ [[buy_and_sell_strategies#​ANDERSON]] ​ | | |  {{glyphicon>​ok?​12}} ​ | |
 ^ [[buy_and_sell_strategies#​DISABLED]] ​  *See explanation below | | | | | ^ [[buy_and_sell_strategies#​DISABLED]] ​  *See explanation below | | | | |
  
 +==== SIGNAL ====
 +
 +This strategy allows you to integrate approved external signal provider'​s signals or your own TradingView signals.
 +SIGNAL is true when ProfitTrailer receives a correctly formatted signal from an external source.
 +If you have notifications turned on these will trigger when a signal buy or sell is made.
 +
 +If using SIGNAL either an approved external provider signal or your own TradingView signal is required. ​
 +
 +These Signals are created outside of the ProfitTrailer product, see this page for details on [[https://​wiki.profittrailer.com/​doku.php?​id=signals|how to integrate with signals]]
 +
 +----
 +
 +**The Numbers**
 +
 +Valid Values: no additional buy or sell values are associated with this strategy as everything needed to signal a trade is derived from the signal being received from the external source. Your other buy and sell settings criteria still need to be met.
 +
 +----
 + 
 +**Examples**
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_strategy]] = SIGNAL''​ → buy will happen when a valid signal is received and your other settings buy criteria have been met. i.e. min_buy_volume\\
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_strategy]] = SIGNAL''​ → Sell will happen when a valid signal is received and your other settings sell criteria have been met. i.e. GAIN percentage profit has been achieved\\
 +
 +**Notes:​**  ​
 +  - If using SIGNAL either an approved external provider signal or your own TradingView signal is required. These Signals are created outside of the ProfitTrailer product, see this page for details on [[https://​wiki.profittrailer.com/​doku.php?​id=signals|how to integrate with signals]]
 +  - Signals are not part of your ProfitTrailer product license and require a separate paid subscription to either an approved supplier'​s signals service and/or the TradingView integration service. These subscriptions are available for purchase from the [[https://​profittrailer.com/​shop/​|ProfitTrailer Shop]].
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 +----
 ==== LOWBB ==== ==== LOWBB ====
  
Line 340: Line 380:
 [[buy_and_sell_strategies|TOP]] [[buy_and_sell_strategies|TOP]]
 \\ \\
 +
 ---- ----
 +==== HMAGAIN ====
 +
 +This buy/sell strategy is true when the current ask/bid price is above (positive ''​buy/​sell_value''​) or below (negative ''​buy/​sell_value''​) the lowest of the two HMA lines specified. It does not matter if the fast or slow HMA line is lower, the bot always looks at the value of the lower line.
 +
 +If a positive value is used the ask/bid price must be greater than (or equal to (for selling)) the value of the lower HMA band multiplied by (1 + ''​buy/​sell_value''​ expressed as a percentage).\\
 +If a negative value is used the ask/bid price must be less than (or equal to (for selling)) the value of the lower HMA band multiplied by (1 + ''​buy/​sell_value''​ expressed as a percentage).
 +
 +----
 +**The Numbers**
 +
 +Valid Values: positive or negative decimal values.
 +
 +1 = 1% of the price above the lowest of the two HMA lines\\
 +0 = Right on top of the lowest HMA line.\\
 +-0.5 = 0.5% of the price below the lowest of the two HMA lines\\
 +
 +----
 +**The Parameters**
 +
 +''​[[indicators.properties#​HMA_candle_period]]''​\\
 +''​[[indicators.properties#​HMA_fast_length]]''​\\
 +''​[[indicators.properties#​HMA_slow_length]]''​\\
 +
 +----
 +**The Formula**
 +
 +Positive ''​buy/​sell_value''​
 +<file java>
 +buy price > lowest HMA * (1 + ABS(buy/​sell_value/​100))
 +sell price >= lowest HMA * (1 + ABS(buy/​sell_value/​100))
 +</​file>​
 +Negative ''​buy/​sell_value''​
 +<file java>
 +buy price < lowest HMA * (1 - ABS(buy/​sell_value/​100))
 +sell price <= lowest HMA * (1 - ABS(buy/​sell_value/​100))
 +</​file>​
 +
 +----
 +**Examples**
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_value]] = 0.8''​ → sell zone begins 0.8% (of the price) above the lowest HMA line. Bid price must be equal to or greater than this value. ''​[[pairs.properties#​DEFAULT_A_sell_value_limit]]''​ must be greater than 0.8 if used.\\
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = 0''​ →  buy zone begins on the lowest HMA line. Ask price must be greater than this value. ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be greater than 0 if used.\\
 +
 +''​[[dca.properties#​DEFAULT_DCA_A_buy_value|DEFAULT_DCA_B_buy_value]] = -1''​ →  buy zone begins 1% (of the price) below the lowest HMA line. Ask price must be less than this value. ''​[[dca.properties#​DEFAULT_DCA_A_buy_value_limit|DEFAULT_DCA_B_buy_value_limit]]''​ must be less than -1 if used.\\
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 +----
 +==== DEMAGAIN ====
 +
 +This buy/sell strategy is true when the current ask/bid price is above (positive ''​buy/​sell_value''​) or below (negative ''​buy/​sell_value''​) the lowest of the two DEMA lines specified. It does not matter if the fast or slow DEMA line is lower, the bot always looks at the value of the lower line.
 +
 +If a positive value is used the ask/bid price must be greater than (or equal to (for selling)) the value of the lower DEMA band multiplied by (1 + ''​buy/​sell_value''​ expressed as a percentage).\\
 +If a negative value is used the ask/bid price must be less than (or equal to (for selling)) the value of the lower DEMA band multiplied by (1 + ''​buy/​sell_value''​ expressed as a percentage).
 +
 +----
 +**The Numbers**
 +
 +Valid Values: positive or negative decimal values.
 +
 +1 = 1% of the price above the lowest of the two DEMA lines\\
 +0 = Right on top of the lowest DEMA line.\\
 +-0.5 = 0.5% of the price below the lowest of the two DEMA lines\\
 +
 +----
 +**The Parameters**
 +
 +''​[[indicators.properties#​DEMA_candle_period]]''​\\
 +''​[[indicators.properties#​DEMA_fast_length]]''​\\
 +''​[[indicators.properties#​DEMA_slow_length]]''​\\
 +
 +----
 +**The Formula**
 +
 +Positive ''​buy/​sell_value''​
 +<file java>
 +buy price > lowest DEMA * (1 + ABS(buy/​sell_value/​100))
 +sell price >= lowest DEMA * (1 + ABS(buy/​sell_value/​100))
 +</​file>​
 +Negative ''​buy/​sell_value''​
 +<file java>
 +buy price < lowest DEMA * (1 - ABS(buy/​sell_value/​100))
 +sell price <= lowest DEMA * (1 - ABS(buy/​sell_value/​100))
 +</​file>​
 +
 +----
 +**Examples**
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_value]] = 0.8''​ → sell zone begins 0.8% (of the price) above the lowest DEMA line. Bid price must be equal to or greater than this value. ''​[[pairs.properties#​DEFAULT_A_sell_value_limit]]''​ must be greater than 0.8 if used.\\
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = 0''​ →  buy zone begins on the lowest DEMA line. Ask price must be greater than this value. ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be greater than 0 if used.\\
 +
 +''​[[dca.properties#​DEFAULT_DCA_A_buy_value|DEFAULT_DCA_B_buy_value]] = -1''​ →  buy zone begins 1% (of the price) below the lowest DEMA line. Ask price must be less than this value. ''​[[dca.properties#​DEFAULT_DCA_A_buy_value_limit|DEFAULT_DCA_B_buy_value_limit]]''​ must be less than -1 if used.\\
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 +----
 +
 ==== SMASPREAD ==== ==== SMASPREAD ====
  
Line 424: Line 568:
 [[buy_and_sell_strategies|TOP]] [[buy_and_sell_strategies|TOP]]
 \\ \\
 +
 +----
 +
 +==== HMASPREAD ====
 +
 +This buy/sell strategy is true when the spread between fast and slow HMA is larger (bigger spread) than (or equal to (for selling)) the ''​buy/​sell_value''​.
 +
 +With HMASPREAD the current price does not matter, only the magnitude of the spread.
 +----
 +**The Numbers**
 +
 +Valid Values: positive or negative decimal numbers. ​
 +
 +----
 +**The Parameters**
 +
 +''​[[indicators.properties#​HMA_candle_period]]''​\\
 +''​[[indicators.properties#​HMA_fast_length]]''​\\
 +''​[[indicators.properties#​HMA_slow_length]]''​\\
 +----
 +**The Formula**
 +
 +<file java>
 +%HMASLOW = HMA(closeprices,​ HMA_slow_length)
 +
 +%HMAFAST = HMA(closeprices,​ HMA_fast_length)
 +
 +%Spread = ((%HMAFAST / %HMASLOW) - 1) * 100
 +</​file>​
 +
 +It is this %Spread that we display \\
 +
 +----
 +**Examples**\\
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = -0.5''​ → buy strategy is true when the calculated spread is larger than -0.5%. (Fast HMA is LOWER than Slow HMA). ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be less than -0.5 if used. \\
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_value]] = 0.6''​ → sell strategy is true when the calculated spread is 0.6% or larger. (Fast HMA is HIGHER than Slow HMA). ''​[[pairs.properties#​DEFAULT_A_sell_value_limit]]''​ must be greater than 0.6 if used.\\
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 +----
 +
 +==== DEMASPREAD ====
 +
 +This buy/sell strategy is true when the spread between fast and slow DEMA is larger (bigger spread) than (or equal to (for selling)) the ''​buy/​sell_value''​.
 +
 +With DEMASPREAD the current price does not matter, only the magnitude of the spread.
 +----
 +**The Numbers**
 +
 +Valid Values: positive or negative decimal numbers. ​
 +
 +----
 +**The Parameters**
 +
 +''​[[indicators.properties#​DEMA_candle_period]]''​\\
 +''​[[indicators.properties#​DEMA_fast_length]]''​\\
 +''​[[indicators.properties#​DEMA_slow_length]]''​\\
 +----
 +**The Formula**
 +
 +<file java>
 +%DEMASLOW = DEMA(closeprices,​ DEMA_slow_length)
 +
 +%DEMAFAST = DEMA(closeprices,​ DEMA_fast_length)
 +
 +%Spread = ((%DEMAFAST / %DEMASLOW) - 1) * 100
 +</​file>​
 +
 +It is this %Spread that we display \\
 +
 +----
 +**Examples**\\
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = -0.5''​ → buy strategy is true when the calculated spread is larger than -0.5%. (Fast DEMA is LOWER than Slow DEMA). ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be less than -0.5 if used. \\
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_value]] = 0.6''​ → sell strategy is true when the calculated spread is 0.6% or larger. (Fast DEMA is HIGHER than Slow DEMA). ''​[[pairs.properties#​DEFAULT_A_sell_value_limit]]''​ must be greater than 0.6 if used.\\
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 ---- ----
  
Line 531: Line 758:
 [[buy_and_sell_strategies|TOP]] [[buy_and_sell_strategies|TOP]]
 \\ \\
 +
 ---- ----
  
 +==== HMACROSS ====
 +
 +This buy/sell strategy is true when the HMA lines have crossed and the spread is larger (bigger spread) than (or equal to (for selling)) the ''​buy/​sell_value''​.
 +
 +The direction of the cross is important. If a positive ''​buy/​sell_value''​ is used the fast HMA line must have crossed above the slow HMA line. If a negative ''​buy/​sell_value''​ is used the fast HMA line must have crossed below the slow HMA line.
 +
 +The cross must take place within the number of ''​cross_candles''​ specified also.
 +
 +----
 +**The Numbers**
 +
 +Valid Values: Positive or negative decimal values.
 +
 +----
 +**The Parameters**
 +
 +''​[[indicators.properties#​HMA_cross_candles]]''​\\
 +''​[[indicators.properties#​HMA_candle_period]]''​\\
 +''​[[indicators.properties#​HMA_fast_length]]''​\\
 +''​[[indicators.properties#​HMA_slow_length]]''​\\
 +----
 +**The Formula**
 +
 +<file java>
 +%HMASLOW = HMA(closeprices,​ HMA_slow_length)
 +
 +%HMAFAST = HMA(closeprices,​ HMA_fast_length)
 +
 +%Spread = ((%HMAFAST / %HMASLOW) - 1) * 100
 +</​file>​
 +
 +It is this %Spread that we display \\
 +A cross must have occurred within the number of ''​[[indicators.properties#​HMA_cross_candles]]''​ specified for the strategy to become true \\
 +
 +----
 +**Examples**
 +
 +''​[[indicators.properties#​HMA_cross_candles]] = 5''​
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = -0.2''​→ buy strategy is true when the calculated spread is larger than -0.2% (Fast HMA is LOWER than Slow HMA) and the Fast HMA crossed below the slow HMA within the last 5 candles (excluding the current candle). ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be less than -0.2 if used. \\
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = 0.05''​→ buy strategy is true when the calculated spread is larger than 0.05% (Fast HMA is ABOVE Slow HMA) and the Fast HMA crossed above the slow HMA within the last 5 candles (excluding the current candle). ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be more than 0.05 if used. \\
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_value]] = 0.6''​ → sell strategy is true when the calculated spread is 0.6% or larger (Fast HMA is HIGHER than Slow HMA) and the Fast HMA crossed above the slow HMA within the last 5 candles (excluding the current candle). ''​[[pairs.properties#​DEFAULT_A_sell_value_limit]]''​ must be more than 0.6 if used. \\
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 +----
 +
 +==== DEMACROSS ====
 +
 +This buy/sell strategy is true when the DEMA lines have crossed and the spread is larger (bigger spread) than (or equal to (for selling)) the ''​buy/​sell_value''​.
 +
 +The direction of the cross is important. If a positive ''​buy/​sell_value''​ is used the fast DEMA line must have crossed above the slow DEMA line. If a negative ''​buy/​sell_value''​ is used the fast DEMA line must have crossed below the slow DEMA line.
 +
 +The cross must take place within the number of ''​cross_candles''​ specified also.
 +
 +----
 +**The Numbers**
 +
 +Valid Values: Positive or negative decimal values.
 +
 +----
 +**The Parameters**
 +
 +''​[[indicators.properties#​DEMA_cross_candles]]''​\\
 +''​[[indicators.properties#​DEMA_candle_period]]''​\\
 +''​[[indicators.properties#​DEMA_fast_length]]''​\\
 +''​[[indicators.properties#​DEMA_slow_length]]''​\\
 +----
 +**The Formula**
 +
 +<file java>
 +%DEMASLOW = DEMA(closeprices,​ DEMA_slow_length)
 +
 +%DEMAFAST = DEMA(closeprices,​ DEMA_fast_length)
 +
 +%Spread = ((%DEMAFAST / %DEMASLOW) - 1) * 100
 +</​file>​
 +
 +It is this %Spread that we display \\
 +A cross must have occurred within the number of ''​[[indicators.properties#​DEMA_cross_candles]]''​ specified for the strategy to become true \\
 +
 +----
 +**Examples**
 +
 +''​[[indicators.properties#​DEMA_cross_candles]] = 5''​
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = -0.2''​→ buy strategy is true when the calculated spread is larger than -0.2% (Fast DEMA is LOWER than Slow DEMA) and the Fast DEMA crossed below the slow DEMA within the last 5 candles (excluding the current candle). ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be less than -0.2 if used. \\
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = 0.05''​→ buy strategy is true when the calculated spread is larger than 0.05% (Fast DEMA is ABOVE Slow DEMA) and the Fast DEMA crossed above the slow DEMA within the last 5 candles (excluding the current candle). ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be more than 0.05 if used. \\
 +
 +''​[[pairs.properties#​DEFAULT_A_sell_value]] = 0.6''​ → sell strategy is true when the calculated spread is 0.6% or larger (Fast DEMA is HIGHER than Slow DEMA) and the Fast DEMA crossed above the slow DEMA within the last 5 candles (excluding the current candle). ''​[[pairs.properties#​DEFAULT_A_sell_value_limit]]''​ must be more than 0.6 if used. \\
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 +----
 ==== RSI ==== ==== RSI ====
  
Line 976: Line 1305:
 ---- ----
 → Use **TradingView** to visualize **OBV** with [[https://​www.tradingview.com/​script/​ihKHk5Pd-OBV-for-ProfitTrailer-by-BotIndicators-com/​|this indicator]]. → Use **TradingView** to visualize **OBV** with [[https://​www.tradingview.com/​script/​ihKHk5Pd-OBV-for-ProfitTrailer-by-BotIndicators-com/​|this indicator]].
 +
 +\\
 +[[buy_and_sell_strategies|TOP]]
 +\\
 +
 ---- ----
 +==== PDHIGH ====
  
 +PDHIGH is the previous day high. PDHIGH (though its name suggests a Previous Day) is just a previous **candle**, so you can use it on any supported time period.
  
 +This buy strategy is true when current bid price is above or below the previous candle high of a trading pair.
  
 +----
 +
 +**The Numbers**
 +
 +Valid Values: positive or negative decimal values.
 +
 +So yesterday high for ETHBTC was 0.034432\\
 +Current bid price is about 0.0321190\\
 +So the PDHIGH value is negative (-6.71%).\\ ​
 +
 +----
 +**The Formula**
 +
 +PDHIGH uses a spread calculation as follows:
 +
 +<file java>
 +%Spread = ((%Bid Price / %PDHIGH) - 1) * 100
 +</​file>​
 +
 +It is this %Spread that we display ​
 +
 +----
 +
 +**The Parameters**
 +
 +''​[[indicators.properties#​PDHIGH_candle_period]]''​\\
 +
 +----
 + 
 +**Examples**
 +An example use of this strategy is to buy as soon as the bid price crosses the PDHIGH indicating that a possible break out has occurred. In this case the breakout is to the positive side indicating an upward trend.
 +
 +<file java>
 +DEFAULT_A_buy_strategy = PDHIGH
 +DEFAULT_A_buy_value = 0.00000001
 +DEFAULT_A_buy_value_limit = 30.0
 +</​file>​
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = 0.00000001''​ → buy zone begins 0.00000001% being positive indicates an upward trend. Bid price must be higher than this value. ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be higher than 0.00000001 if used.\\
 +
 +''​[[pairs.properties#​DEFAULT_A_buy_value]] = -0.00000001''​ → negative numbers indicates a downward trend. Bid price must be lower than this value. ''​[[pairs.properties#​DEFAULT_A_buy_value_limit]]''​ must be lower than -0.00000001 if used.\\
  
 \\ \\
 [[buy_and_sell_strategies|TOP]] [[buy_and_sell_strategies|TOP]]
 \\ \\
 +
 ---- ----
 +
 ==== ANDERSON ==== ==== ANDERSON ====
  
  • buy_and_sell_strategies.1547211640.txt.gz
  • Last modified: 2 months ago
  • by armchairguru