Machine learning in trading: theory, models, practice and algo-trading - page 1063

 
FxTrader562:

For me GDMH doesn't seem much difficult to implement if I understood it correctly...But I will look into it again

1.You calculate each polynomial by taking a for loop and getting the summation of multiplication of co-efficient and indicator value inputs like ai*xi

2.Next, feed the individual polynomial to RDF input and train it

3.Next, Calculate the optimal co-efficient using least square method

4.Next, iterate the whole process continuously during the trading period

If I understood it correctly and if I can help you in anyway, then you can write to me.

By the way, I have good sample codes for Lotoptimization() and money management() etc which can be very very helpful if you can get the accuracy and drawdown of the system to a reasonable level. The system doesn't need to be 99% accurate all the time, but drawdown and consecutive losses matter a lot.

All right, but need to implement it correctly: save best model and coefficients for predictors, for next usage

Also different methods of gmdh - fast genetic selection or brute force (I think 1-st)

Also, in this new library you can add multiple agents with different predictors and different settings, the result will be averaged over all agents
 
Vizard_:

You've been told since 4 that it's a rattle in all implementations and kills at once.
Trolling is trolling, but if you have something and someone needs it - send it... The project is open and not yours)))

I'm not greedy. It's purely out of principle, especially since I already gave him a link..... Just forget it..... I plan to finish the rattle, I think Reshetov just did not have time :-(((((. But getting a good optimizer in a box is not a bad idea. But what's coolest. Where you can really make money is one very long forgotten project, but it needs programmers, and where to get them? There are no such people here. By the way, think about it, I have a birthday just in the day of the programmer. .....

 
Maxim Dmitrievsky:

All right, but need to implement it correctly: save best model and coefficients for predictors, for next usage

also different methods of gmdh - fast genetic selection or brute force (I think 1-st)

Also, in this new library you can add multiple agents with different predictors and different settings, the result will be averaged over all agents

To save the best model you need to iterate the whole thing to target a specific value of "Sharp ratio" and "Recovery factor". Until it achieves the required optimisation results, don't trade. I have already implemented it in your previous version. If you want sample code, I can give.

Yes, of course, the fast genetic algorithm. But as I mentioned above don't place trade until it achieves the required results set in the input settings and hence, it doesn't matter.

Let me explore the possibilities of this new library and I will give you feedback.

 
Maxim Dmitrievsky:

In this version I check classification (or logloss) errors on test subset, and choose the best one. This model I save. I think it works well, but current kernel is sucks

And this function choose the best model on transformed predictors

Ok, but how will it repeat the iteration? I mean is it a one time process or is it going to repeat itself after every candle or every hour etc?

That is the most important part.

I am using a third party software developed by my own to iterate the whole thing since I don't know how to do it in MQL5. I mean I was using it in your previous version to check the "sharp ratio" after every optimisation completion.

Have you done anything similar to iterate the whole process continuously after a certain period of time?

 
FxTrader562:

But how will it repeat the iteration? I mean is it a one time process or is it going to repeat itself after every candle or every hour etc?

That is the most important part.

I am using a third party software developed by my own to iterate the whole thing since I don't know how to do it in MQL5.

I will use this 1 iteration process, in tester. Then in that function he transform predictors iteratively and learn the models

I have another version for optomisator, but in my experience 1 iteration is also good here

 
FxTrader562:

Have you done anything similar to iterate the whole process continuously after a certain period of time?

not yet

if we have a good model - it will work days and weeks, so auto-optimisation is not a priority task
 
Maxim Dmitrievsky:

this 1 iteration process, in tester. Then in that functiion he transform predictors iteratively and learn the models

I have another version for optomisator, but in my experience 1 iteration is also good here

But I don't think that one model can work always without optimization. Especially, when the market changes the best model can fail terribly even after a large value of sharp ratio and other factors...

 
FxTrader562:

Then I think it will be okay if you are continuously optimizing.


By the way, this is the source code what I am talking about:

input string OptimizationParameterCheckSettings="===Settings for saved Optimization paramaters===";

input bool OptimizationParameterCheck=true;

input double SharpRatioRequired=0.3;


Add this code inside tester:

filehnd=FileOpen("SharpRatio_"+_Symbol+(string)_Period+".txt",FILE_READ|FILE_WRITE|FILE_CSV|FILE_ANSI|FILE_COMMON);//--To save the SharpRatio of the last run

double SharpRatio=NormalizeDouble(TesterStatistics(STAT_SHARPE_RATIO),2);

FileWrite(filehnd,SharpRatio);

FileClose(filehnd);


Next, inside start function:

if(SharpRatioLastRun<SharpRatioRequired)

{

Comment("Current trading policy doesn't meet the trading requirement as per last optimization results....So trading has been stopped for sometime");

return;

}


nice method, thanks!

 
Maxim Dmitrievsky:

nice method, thanks!

Ok, but I will repeat that you should seriously consider to add some form of continuous optimization, otherwise, it is going to fail. Because as I said earlier I tried each and every combination of the settings as well as different indicators and multiple timeframes and nothing worked perfectly so far.....

But when I continuously iterate, then it used to work sometimes good. By the way, I have the solution for mine. But I don't like that method of doing it since it should be done by MQL5 and I don't know how to do it in MQL5.

 
FxTrader562:

Ok, but I will repeat that you should seriously consider to add some form of continuous optimization, otherwise, it is going to fail. Because as I said earlier I tried each and every combination of the settings as well as different indicators and multiple timeframes and nothing worked perfectly so far.....

But when I continuously iterate, then it used to work sometimes good.

Because models still sucks ^) with big errors, need models that work longer

for example 2 months learning and 1 week trade
Reason: