5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
Exploring ML methods to increase the profitability of the trading strategy
1. Exploring ML methods to increase the profitability of the trading strategy
Always in touch with the future!
2. About
• Author:
Zakharov Denis Arturovich,
almost graduate student from SPbSUT,
Security Engineer
Google IT Support Professional Certificate
• Research advisor:
Kulikov Evgeny
Master Of ML.
@MisterZurg
2
About speaker
4. Before applying any statistical model on a time series, we want to ensure it’s stationary.
• Mean of the series should not be a function of time;
4
Preparing data
5. Before applying any statistical model on a time series, we want to ensure it’s stationary.
• Mean of the series should not be a function of time;
• Variance of the series should not be a function of time;
5
Preparing data
6. Before applying any statistical model on a time series, we want to ensure it’s stationary.
• Mean of the series should not be a function of time;
• Variance of the series should not be a function of time;
• Covariance of the i-th term and the (i + m)-th term series should not be a function of time.
6
Preparing data
8. # MyBoxCocks использует преобразование Бокса-
Кокса для перевода ряда к стационарному виду
def MyBoxCocks(data: pd.Series):
bc, _ = boxcox(data)
# Отрисовка графика :/
pd.Series(bc).dropna().plot(figsize=(20,8))
return data
8
Box-Cox transformation
10. # MyDifferentiation преобразует ВР к стационарному виду
с через вычисление разницы следующего члена временного
ряда от предыдущего y(t+1) = y(t) + delta
def MyDifferentiation(data: pd.Series):
data = np.array(data)
data = pd.Series(data).iloc[1:] - pd.Series(data).shift(1).dropna()
data.dropna().plot(figsize=(20,8))
return data
10
Differentiation
12. # MyFractionDifferentiation преобразует ВР к стационарно
му виду с через y(t+1) = y(t)* delta
def MyFractionDifferentiation(data: pd.Series, delta):
data = np.array(data)
data = pd.Series(data) / pd.Series(data).shift(delta) - 1
data.dropna().plot(figsize=(20,8))
return data
12
Fractional-Differentiation
14. def MyRoolingMean(data: pd.Series):
# rolling_mean = data.rolling
data = np.array(data)
data = pd.Series(data).rolling(window=1).mean()
data.plot(figsize=(20,8))
return data
14
Rolling Mean