Something interesting, old thread - page 17

 

Ok now the code has no errors or warnings...

but the indy is empty

mladen:
Doc

If you are referring to the "possible loss of data" warning it is because you declared SmAperiod as double and iSma expects the SmaPeriod to be integer. Change the type of SmaPeriod to int and there will be no warning

As of the rest - you are calculating 2 things : a simple moving average and an rsi. You are not calculating neither smoother rsi nor rsi of an average. If you want a sma of an rsi then the code should be like this :

rsi = iRsi(price,RsiPeriod,i,rates_total);

sma = iSma(rsi ,SmaPeriod,i,rates_total);

All this provided that I do understand what are you trying to achieve
Files:
try_3.mq5  4 kb
 

...

Because you declared the drawing buffers as color lines

If you declare drawing buffers as color lines you must have one buffer for data and the next for colors )se the T3 for example ho it is done)

Here is one that work properly as simple lines

dr.house7:
Ok now the code has no errors or warnings... but the indy is empty
Files:
try_3_1.mq5  4 kb
 

I forgot to check it, infact I took the header from your t3 indy

Thanks Mladen I learned a lot with you this time

mladen:
Because you declared the drawing buffers as color lines

If you declare drawing buffers as color lines you must have one buffer for data and the next for colors )se the T3 for example ho it is done)

Here is one that work properly as simple lines
 

Fxdd slippage

Hey guys,

Read this, very interesting, about slippage at fxdd :

NFA hits FXDD with multiple charges including asymmetric slippage, fine will cost it over $3.5m | Forex Magnates

Sorry to clutter your thread but this is something interesting and don't know where to post it.

 

...

brokers are all thieves, nothing new

Big Joe:
Hey guys,

Read this, very interesting, about slippage at fxdd :

NFA hits FXDD with multiple charges including asymmetric slippage, fine will cost it over $3.5m | Forex Magnates

Sorry to clutter your thread but this is something interesting and don't know where to post it.
 

...

Being paranoid (as I partially am ), this sentence from that link struck me :

"Interesting facts: As of March 1, 2011 (when NFA commenced its 2011 audit of FXDD), FXDD had approximately 70,000 U.S. clients. 99% of them traded on the MT4 platform."

dr.house7:
brokers are all thieves, nothing new
 

There is an extent for stealing but when it comes to greed these pigs dont' set any limit.

 

Rsi folating levels ..

Back to the theme This is a rsi floating levels indicator from this post : https://www.mql5.com/en/forum/178733/page13 (with additional information as of what and how it does it) made to work on metatrader5 with some extra specific only for metatrader 5 (the filled array for overbought and oversold zones can be made this way only in metatrader 5)

 

:)

Mladen

what's the meaning of "?" here:

min = rsi< min ? rsi: min;[/PHP]

another thing is this, why metaeditor needs "(int)" after "="?

"i" is int and also the array "prev_calculated"

[PHP]for (int i=(int)MathMax(prev_calculated-1,0);
mladen:
Back to the theme

This is a rsi floating levels indicator from this post : https://www.mql5.com/en/forum/178733/page13 (with additional information as of what and how it does it) made to work on metatrader5 with some extra specific only for metatrader 5 (the filled array for overbought and oversold zones can be made this way only in metatrader 5)

 

...

1. translated to talking language : if rsi < min, min equals rsi else equals (remains) min

2. i and prev_calculated are integers but the MathMax() function is not (it is double) hence the (int) cast is needed to avoid warning message from the compiler (you can omit that and it will work without the (int) too, just that I do not like warning messages from the compiler - better to have none (warning) in case if there is an error)

dr.house7:
Mladen

what's the meaning of "?" here:

min = rsi< min ? rsi: min;[/PHP]

another thing is this, why metaeditor needs "(int)" after "="?

"i" is int and also the array "prev_calculated"

[PHP]for (int i=(int)MathMax(prev_calculated-1,0);
Reason: