Price movement expectation over the labeling window:
----------------------------------------------------
+current natr = (atr / current close) * 100
trade duration candles = (current candle date - trade candle date) // timeframe (in the same time unit)
trade candle
[ current natr label window ]
trade duration candles = 0
-expected trade price movement in the future label window candles from trade opening = trade natr * trade rate
-expected price movement in the future label window candles = current natr * current rate
+expected trade price movement in the future label window candles from trade opening = trade natr * 0.01 * trade rate
+expected price movement in the future label window candles = current natr * 0.01 * current rate
trade candle current candle
| |
]
trade duration candles > 0
-expected trade price movement in the future label window candles from trade opening = trade natr * trade rate
-expected trade price movement in the future trade duration candles window from trade opening = trade natr * trade rate * trade duration candles / label window
-expected price movement in the future label window candles = current natr * current rate
-expected price movement in the future trade duration candles window = current natr * current rate * trade duration candles / label window
+expected trade price movement in the future label window candles from trade opening = trade natr * 0.01 * trade rate
+expected trade price movement in the future trade duration candles window from trade opening = trade natr * 0.01 * trade rate * trade duration candles / label window
+expected price movement in the future label window candles = current natr * 0.01 * current rate
+expected price movement in the future trade duration candles window = current natr * 0.01 * current rate * trade duration candles / label window
trade 1 candle trade 2 candle current candle
| | |
[ trade 2 natr label window ]
]
-expected trade price movement in the future trade duration candles window from trade opening approximation = trade natr * trade rate * trade duration candles / label window
-expected price movement in the future trade duration candles window approximation = current natr * current rate * trade duration candles / label window
+expected trade price movement in the future trade duration candles window from trade opening approximation = trade natr * 0.01 * trade rate * trade duration candles / label window
+expected price movement in the future trade duration candles window approximation = current natr * 0.01 * current rate * trade duration candles / label window
https://github.com/sponsors/robcaulk
"""
- version = "3.6.5"
+ version = "3.6.6"
@cached_property
def __optuna_config(self) -> dict:
return model
def get_label_period_candles(self, pair: str) -> int:
- label_period_candles = self.__optuna_period_params.get(pair, {}).get(
+ label_period_candles = self.__optuna_period_params.get(pair).get(
"label_period_candles"
)
if label_period_candles:
self, pair: str, namespace: str, study: optuna.study.Study
) -> None:
if namespace == "hp":
- best_params = self.__optuna_hp_params.get(pair, {})
+ best_params = self.__optuna_hp_params.get(pair)
elif namespace == "period":
- best_params = self.__optuna_period_params.get(pair, {})
+ best_params = self.__optuna_period_params.get(pair)
if best_params:
study.enqueue_trial(best_params)
else:
INTERFACE_VERSION = 3
def version(self) -> str:
- return "3.2.11"
+ return "3.2.12"
timeframe = "5m"
return dataframe
def get_label_period_candles(self, pair: str) -> int:
- label_period_candles = self.__period_params.get(pair, {}).get(
+ label_period_candles = self.__period_params.get(pair).get(
"label_period_candles"
)
if label_period_candles:
peaks_prominence = (
dataframe["close"].iloc[-1]
* ta.NATR(dataframe, timeperiod=label_period_candles).iloc[-1]
- * 0.0025
+ * 0.005
)
min_peaks, _ = find_peaks(
-dataframe["low"].values,