Jump to content

Need Help for EA


kapri65

Recommended Posts

The arrows are in buffer #2(green) and buffer #3(red)

If there is no arrow on a given bar, the return value for this buffer should be EMPTY_VALUE

Make sure that you are passing all of the 7 external parameter in right order

Params used as comment (like separator1) can be passed as ""

To get a green arrow:

double val=iCustum(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,2,shift) where shift=bar you are looking at...could be 0,1, or any bar prior

If(val==EMPTY_VALUE) -> there is no arrow on that bar

Same for the red arrow where you have to use buffer #3 (the param prior to shift)

Didn't test it, but could work

Link to comment
Share on other sites

Can't make it work, I tried with

 

double rsi1=iCustom(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,2,1); // (...,true,2,0) green arrow

double rsi2=iCustom(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,3,1); // (...,true,3,0) red arrow

 

if (rsi1 != EMPTY_VALUE)

return(SIGNAL_BUY);

if (rsi2 != EMPTY_VALUE)

return(SIGNAL_SELL);

 

Also ask how to open an order in the exact moment that the arrow appears? not when the bar close.

 

Any help please?

Thanks :)

Edited by kapri65
Link to comment
Share on other sites

Can't make it work, I tried with

 

double rsi1=iCustom(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,2,1); // (...,true,2,0) green arrow

double rsi2=iCustom(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,3,1); // (...,true,3,0) red arrow

 

if (rsi1 != EMPTY_VALUE)

return(SIGNAL_BUY);

if (rsi2 != EMPTY_VALUE)

return(SIGNAL_SELL);

 

Also ask how to open an order in the exact moment that the arrow appears? not when the bar close.

 

Any help please?

Thanks :)

 

To test, try this:

 

double rsi1=iCustom(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,2,1);  // (...,true,2,0) green arrow
  double rsi2=iCustom(NULL,0,"Regular RSI Div","",7,"", 0.0001,-0.0001,0,true,3,1);  // (...,true,3,0) red arrow

Print("Rsi1: " + Rsi1)
Print("Rsi2: " + Rsi2)

 

Change the shift value to a time when there is an arrow on the screen. This will help you find out what the value is when there is an arrow.

Link to comment
Share on other sites

First thing, I wouldn't rely on a signal on the current bar, because lots of indis are repainting at least the current bar

Next I would let the EA run in visual mode and attach the RSI indi so that you can see whether the indi probably repaints the arrows even a few bars back...if so you might forget about it

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...