You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
What problems? Need my help?
I think we have it handled. I appreciate the assistance though. :)
Things are going to start to get more complicated, so here is the next instalment (TestRex) to reproduce the following (please note the ATR indicator with a level line for reference):
Now, ask away, about any doubts you may have.
EDIT: Also, please note that I have introduced the concept of a Macro instead of a support function. Macros can be used to make code more readable, especially when you need less overhead of function calls in favour of execution speed.
Things are going to start to get more complicated, so here is the next instalment (TestRex) to reproduce the following (please note the ATR indicator with a level line for reference):
Now, ask away, about any doubts you may have.
EDIT: Also, please note that I have introduced the concept of a Macro instead of a support function. Macros can be used to make code more readable, especially when you need less overhead of function calls in favour of execution speed.
Oh wow. This is some next level stuff.
This one is going to take me a little longer to digest. Will post back then or when I have hit a wall I can't get past.
Ok, no problem! This thread is turning into a tutoring session, so no worries.
Here is an update ...
Given, that when an Indicator gets to be more complex or highly depends on data from other indicators, it can begin to slow down. So it is up to the coder, to improve its efficiency in terms of speed.
In these cases, one can opt for the use of macros instead of functions, even if macros are not so "easy on the eyes".
The following code is equivalent the the previous post, but uses macros instead of function calls in the OnCalculate event handler. Compare the two and see which of the two is your cup of tea (or coffee).
Here is an update ...
Given, that when an Indicator gets to be more complex or highly depends on data from other indicators, it can begin to slow down. So it is up to the coder, to improve its efficiency in terms of speed.
In these cases, one can opt for the use of macros instead of functions, even if macros are not so "easy on the eyes".
The following code is equivalent the the previous post, but uses macros instead of function calls in the OnCalculate event handler. Compare the two and see which of the two is your cup of tea (or coffee).
Wow, is it normal to be a little intimidated by that?
Ok, what I am going to do is write these out by hand both for this and also replacing parts of my other project. Hopefully between the two I can start to wrap my head around it.
I'm more or less understanding them individually, but putting it all together in my head is a little harder since I didn't write them myself.
It's totally OK not to use macros and only use functions. Most coders don't really worry too much much about code efficiency, so there is no need to feel overwhelmed. Stick to what you know and understand.
It's totally OK not to use macros and only use functions. Most coders don't really worry too much much about code efficiency, so there is no need to feel overwhelmed. Stick to what you know and understand.
Ok, I'm back on the job. Had a busy day or so but now I'm on it. Hope to have a post for you in a few hours. :)
I just realized that the picture in one of your last posts doesn't show up for me.What does show up for you? Remember that I stated that I added the ATR with level for comparison with the coded indicator.
What does show up for you? Remember that I stated that I added the ATR with level for comparison with the coded indicator.
Just a white square.
So I'm putting the ATR on the same window as the Rex together with a line for the threshold?