Машинное обучение в трейдинге: теория, модели, практика и алготорговля - страница 3445

[Удален]  
Aleksey Vyazmikin #:

Точно не помню, но там из оперы "слишком сложно - я хотел иначе". Начал искать лазейки в ТЗ, мол можно двояко чего то там интерпретировать, при том, что я его фактически с его слов ему составил...

Его величество фриланс.. и так расценки почти бесплатные, если на доску посмотреть 
 
Maxim Dmitrievsky #:
Его величество фриланс.. и так расценки почти бесплатные, если на доску посмотреть 

Да, нервотрепка была знатной. Но расценки выше средних заказов во фрилансе.

 
Maxim Dmitrievsky #:
Там про синтетический контроль, я его с первого захода не понял, потому что в книге как-то расплывчато было, еще и на агл.

там нужны признаки не связаны с ценой что уже как бы вганяет в ступор.. те где такие взять

[Удален]  
mytarmailS #:

там нужны признаки не связаны с ценой что уже как бы вганяет в ступор.. те где такие взять

Пока не готов ничего сказать ) Тем более что в козуле все направлено на оценку причинно-следственного эффекта, а нам надо ТС, а не оценку

 
mytarmailS #:

там нужны признаки не связаны с ценой что уже как бы вганяет в ступор.. те где такие взять

На фондовых рынках полно признаков, не связанных с ценой

 
СанСаныч Фоменко #:

На фондовых рынках полно признаков, не связанных с ценой

назви 5 штук хотябы

[Удален]  

Казалось бы простая для AGI задача

can you write a pseudocode of this code?
n_clusters = 25
models = []
for i in range(1):
    data = meta_learner(5, 25, 2, 0.3, n_clusters=n_clusters, algorithm=0)
    
    for clust in data['clusters'].unique():
        print('Learn ' + str(i) + ' iter ' + str(clust) + ' model')
        models.append(fit_final_models(data['clusters'].apply(lambda x: 1 if x == clust else 0)))

models.sort(key=lambda x: x[0])
test_model(models[-1][1:], plt=True)
1. Set the number of clusters to 25.
2. Initialize an empty list to store the models.
3. For each iteration (in this case, only one iteration):
    a. Call the `meta_learner` function with the following parameters:
        - Number of folds: 5
        - Number of clusters: 25
        - Number of neighbors: 2
        - Threshold: 0.3
        - Algorithm: 0
    b. Iterate over the unique cluster labels in the data returned by `meta_learner`:
        - Print a message indicating the iteration number and cluster number.
        - Call the `fit_final_models` function to fit a model to the data where the cluster label matches the current cluster number.
        - Append the fitted model to the `models` list.
4. Sort the `models` list based on the first element of each tuple (the score).
5. Call the `test_model` function, passing in the sorted `models` list and setting `plt` to `True` to plot the results.
can you write a python code from this pseudocode?
1. Set the number of clusters to 25.
2. Initialize an empty list to store the models.
3. For each iteration (in this case, only one iteration):
    a. Call the `meta_learner` function with the following parameters:
        - Number of folds: 5
        - Number of clusters: 25
        - Number of neighbors: 2
        - Threshold: 0.3
        - Algorithm: 0
    b. Iterate over the unique cluster labels in the data returned by `meta_learner`:
        - Print a message indicating the iteration number and cluster number.
        - Call the `fit_final_models` function to fit a model to the data where the cluster label matches the current cluster number.
        - Append the fitted model to the `models` list.
4. Sort the `models` list based on the first element of each tuple (the score).
5. Call the `test_model` function, passing in the sorted `models` list and setting `plt` to `True` to plot the results.
from sklearn.cluster import KMeans
from sklearn.neighbors import NearestNeighbors
from sklearn.neighbors import KNeighborsClassifier
from sklearn.model_selection import StratifiedKFold
from sklearn.model_selection import train_test_split
from sklearn.metrics import accuracy_score
import matplotlib.pyplot as plt

# Set the number of clusters
num_clusters = 25

# Initialize an empty list to store the models
models = []

# For each iteration (in this case, only one iteration)
for i in range(1):
    # Call the meta_learner function with the following parameters:
    # - Number of folds: 5
    # - Number of clusters: 25
    # - Number of neighbors: 2
    # - Threshold: 0.3
    # - Algorithm: 0
    meta_data = meta_learner(n_folds=5, n_clusters=num_clusters, n_neighbors=2, threshold=0.3, algorithm=0)

    # Iterate over the unique cluster labels in the data returned by meta_learner
    for cluster_label in np.unique(meta_data['cluster_label']):
        # Print a message indicating the iteration number and cluster number
        print(f'Iteration: {i}, Cluster: {cluster_label}')

        # Call the fit_final_models function to fit a model to the data where the cluster label matches the current cluster number
        model = fit_final_models(meta_data[meta_data['cluster_label'] == cluster_label])

        # Append the fitted model to the models list
        models.append((model.score(X_test, y_test), model))

# Sort the models list based on the first element of each tuple (the score)
models.sort(key=lambda x: x[0], reverse=True)

# Call the test_model function, passing in the sorted models list and setting plt to True to plot the results
test_model(models, plt=True)

Теперь не работает.

 
mytarmailS #:

назви 5 штук хотябы

Фондовые рынки.

Цена акции - это оценка рынком стоимости предприятия. Берем бухгалтерский баланс, там сотни показателей, влияющих на стоимость предприятия. Амортизация основных фондов и вложения в основной капитала - уж точно связаны с ценой акции... По-любому, имеется основа для широчайших, главное содержательных, рассуждений о признаках, влияющих на цену акции.  

Товарные рынки.

Ситуация аналогичная.

А форекс - это практически казино

[Удален]  

Примеры как можно использовать кластеризацию двумя рязными способами

На выходных загружу ботов в кодобазу еще

https://www.mql5.com/ru/articles/14548

Кластеризация временных рядов в причинно-следственном выводе
Кластеризация временных рядов в причинно-следственном выводе
  • www.mql5.com
Алгоритмы кластеризации в машинном обучении — это важные алгоритмы обучения без учителя, которые позволяют разделять исходные данные на группы с похожими наблюдениями. Используя эти группы, можно проводить анализ рынка для конкретного кластера, искать наиболее устойчивые кластеры на новых данных, а также делать причинно-следственный вывод. В статье предложен авторский метод кластеризации временных рядов на языке Python.
 
Maxim Dmitrievsky #:

Примеры как можно использовать кластеризацию двумя рязными способами

На выходных загружу ботов в кодобазу еще

https://www.mql5.com/ru/articles/14548

Оперативно Вы статью написали - не угнаться!

Только, почему то у меня ощущение, что используете лингвистические модели - уж как то странно звучит текст в некоторых моментах...