[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [amibroker] some functional help needed in modifying this afl


  • Date: Thu, 19 Nov 2009 22:38:56 +0530
  • From: Deepak Patade <iamdeepakpatade@xxxxxxxxx>
  • Subject: Re: [amibroker] some functional help needed in modifying this afl

PureBytes Links

Trading Reference Links



it gives syntax error 31 , expecting '('

On Thu, Nov 19, 2009 at 10:08 PM, wavemechanic <fimdot@xxxxxxxxxxxxxx> wrote:
 

Here is one way to check for sequential dots
 
signal = iif(ref(finalmovavg < L, -1) and finalmovavg < L, 1, 0);//2 green in a row
----- Original Message -----
Sent: November 19, 2009 11:22 AM
Subject: Fwd: [amibroker] some functional help needed in modifying this afl

any takers on this
can i use flip or something like that
learned ones
do suggest

---------- Forwarded message ----------
From: Deepak Patade <iamdeepakpatade@xxxxxxxxx>
Date: Thu, Nov 19, 2009 at 6:21 PM
Subject: [amibroker] some functional help needed in modifying this afl [1 Attachment]
To: amibroker@xxxxxxxxxxxxxxx


 
[Attachment(s) from Deepak Patade included below]

i have a afl triangular , i slightly modified it to get signals
i want signal every time a green dot appears for two consecutive times and if after one green dot a red appers the previous is green is to be nullified and it has to wait again for two green dots in a sequence.( the other way for red dots also)
BUT
afl gives redundant signal
see file attached
what is to be incorporated to filter this ,
I know somethingis missing tried hard
This is a traingular moving average ( afl library)  slightly modified by me
 
Odd=13;//enter Odd numbers only
CoefOdd=round(Odd/2);
Even=12;//enter Even numbers only
Coefeven=Even/2;
Coefeven2=Coefeven+1;
CongestionPercent=2.8;/*Set % above/below Moving average for congestion / sideways market*/
TriangularOdd=MA(MA(C,CoefOdd),CoefOdd);
TriangularEven=MA(MA(C,Coefeven),Coefeven2);
finalMov_avg=IIf(Odd > even,triangularOdd,TriangularEven);
colordots = IIf(finalMov_avg < L,colorBrightGreen,IIf(finalMov_avg > H,colorRed,colorWhite));
Buy = Cross(C,finalMov_avg); Buy = Ref(Buy,-1); BuyPrice = O;
Sell = Cross(finalMov_avg,C); Sell = Ref(Sell,-1); SellPrice = O;
SetBarsRequired(-2,-2);
SetChartOptions(0, chartShowDates);
Plot(C,"\nClose",colorWhite,64);
Plot(finalMov_avg,"\finalMov_avg",colordots,styleDots|styleNoLine);
Color=colorBrightGreen;//select Moving average line color
tickercolor=colorBlack;//select price color
Plot(finalMov_avg,"",IIf(C < finalmov_avg,colorRed,Color),styleLine|styleThick);
Plot(C,"",tickercolor,styleCandle);
Short = Sell;
Cover = Buy;
Buy = ExRem(Buy,Sell);
Sell= ExRem(Sell,Buy);
Short=ExRem(Short,Cover);
Cover=ExRem(Cover,Short);
 
Please help out





__._,_.___


**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/





Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___