So as long as you include 10 inputs in iCustom it will work okay?
If your default parameters are okay then you should be able to make the call without passing any but i can imagine that if you want to override the 150th parameter it could get a bit of a problem.
If your default parameters are okay then you should be able to make the call without passing any but i can imagine that if you want to
override the 150th parameter it could get a bit of a problem.
Thanks for this info. Seems the best way is to just have the calculations in the EA.
That's rarely a good idea. It's a false assumption that including the code in the EA will improve performance.
About parameters, you need to sort your indicators parameters to put the relevant ones at the top. Then as explained by Drazen, set the values of the ones that matters and let the other one with default values.
[in] The name of the custom indicator, with path relative to the root directory of indicators (MQL5/Indicators/). If an indicator is located in a subdirectory, for example, in MQL5/Indicators/ [in] input-parameters of a custom indicator, separated by commas. Type and order of parameters must match. If there is no parameters specified, then...
Alain Verleyen: It's a waste of time and
made things more complicated for 0 benefit. (In most cases, there can also have exceptions).
I think when you include the code with the EA the IND is calculated using the same thread as the EA. I make that assumption because the EA is way slower when you bake in indicator code.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
So as long as you include 10 inputs in iCustom it will work okay?
If your default parameters are okay then you should be able to make the call without passing any but i can imagine that if you want to override the 150th parameter it could get a bit of a problem.
So as long as you include 10 inputs in iCustom it will work okay?
You can include as many as you want, but they will be copied in order they are declared in the indicator.
If you add 10, 20, or 50 parameters to the iCustom call, they will be copied to the first 10, 20 or 50 input values of the indicator.
BTW, I don't know if there is any limit to the number of arguments in the MQL4 function call.
Does anyone know if there is a limit on number of inputs allowed in EA? - MQL5 programming forum 2020.05.06
If your default parameters are okay then you should be able to make the call without passing any but i can imagine that if you want to override the 150th parameter it could get a bit of a problem.
Yes
Does anyone know if there is a limit on number of inputs allowed in EA? - MQL5 programming forum 2020.05.06
Thanks for this info. Seems the best way is to just have the calculations in the EA.
Thanks for this info. Seems the best way is to just have the calculations in the EA.
That's rarely a good idea. It's a false assumption that including the code in the EA will improve performance.
About parameters, you need to sort your indicators parameters to put the relevant ones at the top. Then as explained by Drazen, set the values of the ones that matters and let the other one with default values.
It's perfectly fine to incorporate the calculation directly into an EA.
Especially when you do not need the visual representation on the chart but only the result of the formula over the last n bars.
You can do that without using any indicator at all and it's completely unnecessary to use iCustom calls.
It's perfectly fine to incorporate the calculation directly into an EA.
Especially when you do not need the visual representation on the chart but only the result of the formula over the last X bars.
You can do that without using any indicator at all and it's completely unnecessary to use iCustom calls.
It's a waste of time and made things more complicated for 0 benefit.
That would depend on the application.
There are always drawbacks and benefits and sometimes it's not possible to call for an indicator because it isn't available on the target system.
And i disagree that it is a waste of time because by working with complex matters you gain understanding and knowledge is power.
It's a waste of time and made things more complicated for 0 benefit. (In most cases, there can also have exceptions).
I think when you include the code with the EA the IND is calculated using the same thread as the EA. I make that assumption because the EA is way slower when you bake in indicator code.