Few quick questions - page 3

 

Well here it is.

I used Alligator due to its no. of arguments. The outcome is pretty boring ;)

Please feel free to play around with it if you want.

try e.g.

                diJaws[i]  = (iCustom(NULL,0, "Alligator",jaw_period, jaw_shift, 0,i) - 
                              iCustom(NULL,0, "Alligator",jaw_period, jaw_shift, teeth_period, teeth_shift, lips_period, lips_shift, ma_method, applied_price,   0,i))/Point;
                diTeeth[i] = (iCustom(NULL,0, "Alligator",jaw_period, jaw_shift, 1,i) - 
                              iCustom(NULL,0, "Alligator",jaw_period, jaw_shift, teeth_period, teeth_shift, lips_period, lips_shift, ma_method, applied_price,   1,i))/Point;
                diLips[i]  = (iCustom(NULL,0, "Alligator",jaw_period, jaw_shift, 2,i) - 
                              iCustom(NULL,0, "Alligator",jaw_period, jaw_shift, teeth_period, teeth_shift, lips_period, lips_shift, ma_method, applied_price,   2,i))/Point;


Convinced?

Gooly

Files:
 
gooly:

Well here it is.

I used Alligator due to its no. of arguments. The outcome is pretty boring ;)

Please feel free to play around with it if you want.

try e.g.

Convinced?

No, Confused ? yes . . .

The standard Alligator that ships with MT4 has the following 6 externs . . .

extern int JawsPeriod=13;
extern int JawsShift=8;
extern int TeethPeriod=8;
extern int TeethShift=5;
extern int LipsPeriod=5;
extern int LipsShift=3;

. . . why are you passing the 6 externs, the first of which you have changed from the default value of 13 to 20, plus ma_method and applied_price ?

 

I have to change my mq4 a bit.

Please load Alligator.mq4 and save it as Alligator2.mq4.

Now you can see the difference if you play with the arguments..

Files:
 
RaptorUK:. . . why are you passing the 6 externs, the first of which you have changed from the default value of 13 to 20, plus ma_method and applied_price ?
May that is the difference between iAlligator and Alligator? But you are right, just delete them please.
Arg-window
 

now I know from where I took ma_method and applied_price.

I took it from the 'Help' of the editor but look here too https://docs.mql4.com/indicators/ialligator

 
gooly:

now I know from where I took ma_method and applied_price.

I took it from the 'Help' of the editor but look here too https://docs.mql4.com/indicators/ialligator

Why didn't you simply look at the indicator you were calling ?
 
RaptorUK:
Why didn't you simply look at the indicator you were calling ?


I wanted to create an example for you to play around with. I don't use Alligator and so I wasn't prepared that there were two versions..
 
Proximus:

Hi i have a few quick questions :

1) If i want to apply the icustom to a specific timeframe in this case 5 min, should i put : 5 or PERIOD_M5

2) If i want to add an icustom indicator then if the if i want to use the default values of that indicator can i put in every slot: "default",without "" or otherwise how to do it?

3) Is an exponential moving average applicable to the current bar or i must shift it back?

Actually referring to my OP #2, the "" won't work sorry.If i put a "" in the place of an int or anything other than string it will not load the custom indicator or load it 9999999999 time until my PC freezes.So to resolve it its better to peak in to the indicator, copy its externals and put those in when i call it with an icustom as default, instead of skipping it with "" .

 

Proximus:

2) If i want to add an icustom indicator then if the if i want to use the default values of that indicator can i put in every slot: "default",without "" or otherwise how to do it?

Actually referring to my OP #2, the "" won't work sorry.If i put a "" in the place of an int or anything other than string it will not load the custom indicator or load it 9999999999 time until my PC freezes.So to resolve it its better to peak in to the indicator, copy its externals and put those in when i call it with an icustom as default, instead of skipping it with "" .


The arguments of the indicator called by iCustom have to be the type the indicator requests: if it requires an int (eg. s.a.: extern int Jawsperiod=13) you can
a) leave it (and all the others because this is the first ext. var. in this example) or
b) you put an integer number there (.., 23,...) or
b) your own local integer variable: int myPer=33; .. iCustom(..., myPer, ...);

I doubt that a "" will work and I am sure a "default" will never work!!

Gooly

Reason: