How to proceed with learning to make custom indicators

Back to topics list To post a new topic, please log in or register
avatar
350
Agent86 2015.01.08 21:05
 
I'm confused about what I should be reading

Mql4 custom indicator properties vs Mql5 custom indicator properties.
 
When creating a custom indicator on mql4 it does indeed insert the OnInit() and OnCalculate() functions

For example:
From MQL5 - https://www.mql5.com/en/docs/constants/indicatorconstants/customindicatorproperties
SetIndexBuffer(0,MainBuffer,INDICATOR_DATA);

Should I use INDICATOR_DATA

OR
Should I stick with what is shown using F1 help reference in mql4 ?

Although Oniit() and Calculate() are used but did not want to mix other function usage that may not be allowed

Please advise





avatar
2017
gooly 2015.01.08 22:25 #
 
Take some existing indicators and study them, save them under a different name and then change them acc. to your ideas...
avatar
350
Agent86 2015.01.09 13:50 #
 
Ok, thanks

I just wondered exactly how many mql5 features in the properties documentation that I could not actually use on my code platform ?

I have read some _plot properties and things cannot be used.
Also are the limitations of the number of indicators still going to apply or will this be cross compatible with mql5 after build 600 ?
Where there is no such limitation for the number of indicators buffers etc. ?

Please advise
Thanks again
avatar
735
honest_knave 2015.01.09 17:00 #
 

My advice is to implement as much of the 'new style' / MQL5 as you can get to work with MQL4.

That will be the future, and the quicker you can transition the better.

The documentation is not fully updated, so sometimes you will need to experiment.

In response to your first query, the MQL4 documentation of SetIndexBuffer mentions the use of the data type parameter so why not use it?

avatar
350
Agent86 2015.01.11 19:28 #
 
honest_knave:

My advice is to implement as much of the 'new style' / MQL5 as you can get to work with MQL4.

That will be the future, and the quicker you can transition the better.

The documentation is not fully updated, so sometimes you will need to experiment.

In response to your first query, the MQL4 documentation of SetIndexBuffer mentions the use of the data type parameter so why not use it?

Ok,  thanks

Curious where is the locations of the default indicators, I've checked MQL4/Indicators and experts/indicators folders. Looked and searched all around in just about every folder in Metatrader

I cannot find the default indicators so I can open them in editor and take a look at them.

Please advise

Thanks


avatar
Moderator
3404
GumRai 2015.01.11 20:50 #
 
Agent86:


I cannot find the default indicators so I can open them in editor and take a look at them.
You can open the editor, then open the editor navigator (Ctrl D). then double click on what you want to examine
avatar
735
honest_knave 2015.01.12 19:03 #
 
Agent86:
Ok,  thanks

Curious where is the locations of the default indicators, I've checked MQL4/Indicators and experts/indicators folders. Looked and searched all around in just about every folder in Metatrader

I cannot find the default indicators so I can open them in editor and take a look at them.

Please advise

Thanks


There is a new data structure - take a look here.

Note: I run everything in portable mode, which keeps the data structure as it was

avatar
5
gregkevin 2015.01.19 11:04 #
 
Open the editor and navigate your problem .
Back to topics list  

To add comments, please log in or register