I made one of these things once ... - page 4

 
TheXpert:

1. easily. Especially in MT5.

2. I suspect you are doing without writing any code at all :) yyyy.

1. This is the MT4 forum, so it's all about MT4.

2- Let's not get personal, shall we? There are other threads for flubbing. :)

 
Candid:

The point is that the approximation itself does not interest me too much, I am interested in the possibility of extrapolation. And it is desirable to see some physical meaning behind it. And splines don't seem to be designed for it. What physical sense can be behind splines?

By the way, we were on a first-name basis earlier, weren't we?



About the spline, very interesting approximation, I'll try to explain how I understand it and what you can do with it.

  1. there is a part of history that is described by a 3rd degree polynomial
  2. there is a condition of continuity of derivatives of the first and second degree
  3. this is the only function that "correctly" interpolates an unknown function on a given segment

it's kind of the definition, the cubic spline. Now let's just say that we analyze the motion of an object (it can be any object, an aeroplane, a car, a currency...).

Using of this algorithm on a given part of history, we will find a function (the only one that has speed and acceleration, which is better than none (though I doubt it)). We only have to assume that for some time the object will move at the same speed and acceleration. Extrapolate. And control for the bias (extrapolation error). Further options, you can do it with the arrival of new data, or you can set a threshold for when the discrepancy exceeds a predetermined value, then recalculate.

I may be wrong, but it seems to me that there is something in it and it is the physics...

I try to put you in the plural, there are more programmers here than I am, it was a reference to all. You're getting some edits in your code, I envy you... I can't grow up. I can only post bad ideas...)
 
Prival:

I agree that yes you can, but understand me, I used to program in assembly language too. It's just that once you get used to a good thing, it's very hard to get away from it. Going back to a low level programming language again is very hard. MQL is a low level programming language compared to matcad. Example please, it took me 1 minute to write it

And I'm sure it's calculated correctly. Try to do the same in MQL, calculate double definite integral of Rayleigh-Reiss function that contains Bessel function calculation of first order zero (please don't try to say it's not necessary for market analysis, I personally need it).

S.I. I just have an idea and, for example, I'd like to check it, then I checked it and decided to move on. If this function was vital for building the ATS (you can't do without it), I assure you I would put it to work, and put a very tasty price ...

I do not see any contradiction. The algorithm can be sketched out in Matcad and anywhere else, and if it works, you still need to convert it later to some form acceptable for MT4/5 calculations. Matlab, for example, has code converters, I don't know about matcad - it's better than nothing, although I don't see any problem for your level of knowledge to master simple C constructs.

I think I've just got no need in Matkadec - even in Matkadec there is no algorithm that needs to be translated into MQL.

 
Prival:
I'm trying to use the plural, there are more programmers around here than me, that was addressed to everyone. They're making changes to your code, I envy you... I can't grow up. I can only post bad ideas...)

There are a lot of programmers around, and the value is just in the algorithm, and it can be in any language.

If you can draw a working algorithm on the same Matkad, then even the best programmers will be compared to you as small children for algorithm and logic are always primary, the implementation is secondary.

 
Andrei01:

....

Apparently there was no need to translate it into MQL, even in Matcad, as you say.

It's easier and more efficient to combine MT4 with Matcad. I've done it with the composter a long time ago. I have not seen him for a long time by the way, who knows how he is, what's wrong with him?

 
Andrei01:
Why an unknown? Is it a finite number or an infinite number?

It can be quite large, although this would of course be an abnormal situation.

But in general, let's really stay on the subject. It was said right away (and then repeated) that the code of actual indicators from the beginning was written as a one-time use code. And the topic is not about the programming style. If you want, you can start a topic about when, in what situations, and how much usage of the rules of "big" programming in MQL is justified.

So you seem to be bothered by the bike's lack of an anatomical seat. Well, it's your taste, everyone has the right to make such a bike for themselves, as they see fit.

 
Where are the EA testing stats on this algorithm? Without them, the discussion as well as the topic itself is pointless.
 
Prival:
Now just assume that we are analysing the motion of an object (it could be any object, an aeroplane, a car, a currency...)

We use of this algorithm, on a given stretch of history, to pick a function (the only one, no better (though I doubt it)) that has velocity and acceleration. We only have to assume that for some time the object will move at the same speed and acceleration. Extrapolate. And control for the unconformity (extrapolation error).

Here, I have highlighted the most important word for me. There is a general rule (although probably not without exceptions), after a certain threshold, the better the approximation, the worse the extrapolation result. In principle, I also thought that the derivatives, if they are needed, should be calculated by approximation. But it has to be exactly an "extrapolated" approximation, otherwise we just rake all the noise into those derivatives. Such is the imho.

And I thought Kalman was brought to the result, didn't you describe the problem under Kalman? Or is it broader than that?

 
Candid:

1. it can be quite large, although this would of course be an abnormal situation.

2. But let's really stay on topic. And the topic is not about programming style at all.

1. Even if the number is large, it is still not good to multiply objects uncontrollably. You have to keep an eye on it in any case, so it's better to do it right from the beginning.

2. Apologies for the offtop, I just couldn't resist making a simple and obvious point about programming style... I didn't expect it to resonate so much.

 
C-4:
Where are the EA testing stats on this algorithm? Without them, the discussion as well as the topic itself is pointless.

And where is the EA algorithm?
Reason: