How to form the input values for the NS correctly. - page 30

 
StatBars писал (а) >>
This version of MPS is a bit better, but it's still not what you want, it needs closure, i.e. Short is followed by Long, and vice versa.

What do you want to achieve ("but still not the right one")?

 
rip писал (а) >>

What do you want to achieve ("but still not the right one")?

To find entry points into the market that will not be built on sharp price fluctuations, but at the same time will not be too infrequent. Points on the price maximums and minimums, and the concept of maximum and minimum varies, ie not for a certain period, and those that satisfy certain conditions (when smoothing saved, the distance to the previous minimum of more than n-value points, maybe need other criteria)

What for, in my opinion, it is necessary: to find all objective closed entries into the market, and not manually...

 
StatBars писал (а) >>

To find entry points into the market that are not based on sharp price fluctuations, but at the same time are not too rare. Points on the price maximums and minimums and the term maximum and minimum varies, i.e. not within a certain period, but those that satisfy some conditions (when smoothing is saved, the distance to the previous minimum is greater than n-number of points, maybe some other criteria are needed).

What I think it's for: to find all objective closed entries into the market, and not manually...

Try to use Condelcode + MPS ... On the one hand classification of adjacent pairs, or let's say market patterns at a given moment of time.

On the other hand MPS will allow traceability of a trade. I started down this path, but have so far switched to another idea. Let's move further

discussion into the mail.

 

Mail is in the profile.

 
StatBars писал (а) >>

Email in profile.

>> uh-huh... saw

 
TheXpert >> :

I am posting it here


Function
sqrt(abs(x)) == sax

f(x) = x/(sax + a)

Derivative
f'(x) = (sax/2 + a)/sqr(sax + a)

As a thank you to the RSDN community, the function has been named RSDNFunction. Please use it with that name.

I don't know how to reproduce the RSDNFunction in MQL-4.

I have got something similar:

double RSDNFunction(double x) {
   int a = 2;
   double RSDN = (MathSqrt (MathAbs( x))/2 + a)/ MathSqrt (MathSqrt (MathAbs( x)) + a);
   return ( RSDN);
}

The author of this function has a couple of questions.

First of all - 1. how could negative values appear in this function, because negative values cannot occur a priori under the square root, all the more so if we take a modulo value of the variable? Or maybe the function should print two values at a time, one positive and one negative?

2. What values are recommended for the variable "a"?

 
Kadet >> :

I can't figure out how to reproduce the RSDNFunction in MQL-4.

I've got something similar:

The author of this function has a couple of questions.

First of all, 1. How can negative values appear in this function, because negative values cannot be under the square root a priori, especially if we take a modulo value of the variable? Or should the function give out two values at once, one positive and one negative?

2. What values are recommended for variable "a"?

double RSDNFunction(double x) 
{
   int a = 1;

   double root = MathSqrt(MathAbs( x));
   return ( x/( root + a));
}

double RSDNFunctionDerivative(double x) 
{
   int a = 1;

   double root = MathSqrt(MathAbs( x));
   return (( root/2 + a)/(( root + a)*( root + a)));
}

The more a, the less non-linearity. In my code I use 1 instead of a. In general, Excel helps here, the function is simple.

Note that the derivative function is taken not from y but from x. So be careful when applying the theory in practice.

 
TheXpert >> :

The more a, the less non-linearity. In my code I use 1 instead of a. Anyway, Excel is here to help, the function is simple.

Note that the derivative function is taken not from y but from x. So let's be careful and apply the theory in practice.

TheXpert

Thank you!

And for the warning too.

There's a parenthesis missing in the code.

return ((root/2 + a)/((root + a)*(root + a)));
 
Kadet >>:

В коде скобочки не хватает.

Thank you, corrected.

 
Looks like the topic has closed, no time for discussion :)
Reason: