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

Re: [amibroker] AFL FOR FRACTALS/ALLIGATORS:


  • Date: Wed, 9 Dec 2009 18:42:41 +0530
  • From: "Prashanth" <prash454.ta@xxxxxxxxx>
  • Subject: Re: [amibroker] AFL FOR FRACTALS/ALLIGATORS:

PureBytes Links

Trading Reference Links



You are with a version that is more than 3 years old. Upgrade if you are interested in using AFL's such as these else stick with one's that work on that version.
 
Cheers
 
Prashanth
----- Original Message -----
From: Asis Ghosh
Sent: Wednesday, December 09, 2009 18:12 PM
Subject: Re: [amibroker] AFL FOR FRACTALS/ALLIGATORS:

Its AB-4.8.2 Prof--do have any fix for this AFL for 4.8.2 version---

Asis

Prashanth K wrote:
 

There is no error in the AFL. 


Which version of AB are you using?

Cheers

Prashanth

On Wed, Dec 9, 2009 at 2:44 PM, Asis Ghosh <subhamedicalsjpg@yahoo.co.in> wrote:


This AFL has some error (ERROR-30: SYNTAX ERROR)--can anyone of our experienced member fix it ?

/*
   Bill William's Alligator System II

   Reference Website:
   ==================
  
http://www.alpari-idc.com/en/market-analysis-guide/chaos-theory/alligator-and-gator.html

   Modified from http://www.amibroker.com/library/detail.php?id=100, by Steve
Wiser - slwiserr@xxxxxxcom
   Modified by TohMz  on June 9th, 2008
*/

SetChartOptions( 0, chartShowArrows|chartShowDates );

_SECTION_BEGIN("Price Chart");
_N(Title = StrFormat("{{NAME}}- {{INTERVAL}} {{DATE}} O= %g, H= %g, L= %g, C=
%g (%.1f%%)
V= " +WriteVal( V, 1.0 ) +"\n{{VALUES}}", O, H, L, C, SelectedValue(
ROC( C, 1 )) ));
PriceStyle =
GetPriceStyle();
PriceStyleOpt =
ParamStyle("Price Style")|PriceStyle;

if (PriceStyle==styleCandle)
  
Plot( C, "", colorBlack,  PriceStyleOpt);
else
  
Plot( C, "", IIf( Close >= Ref(C, -1), colorBlue, colorRed ),
PriceStyleOpt);
_SECTION_END();

_SECTION_BEGIN("BW Alligator");
/*** The trend indicators ***/

P=
ParamList("Price", "Close|(H+L)/2|(H+C+L)/3",1);

if (P=="Close")
   A =
C;
  
else
if (P=="(H+C+L)/3")
   A = (
H+C+L)/3;
else
  A = (
H+L)/2;

AlligatorJaw   =
Ref(Wilders(A,13),-8);
AlligatorTeeth =
Ref(Wilders(A,8), -5);
AlligatorLips  =
Ref(Wilders(A,5), -3);

Plot(AlligatorJaw,  "Jaw", ParamColor("Jaw's Color",colorBlue),
ParamStyle("Jaw's Style", styleThick));
Plot(AlligatorTeeth,"Teeth", ParamColor("Teeth's Color",colorRed),
ParamStyle("Teeth's Style", styleThick));
Plot(AlligatorLips, "Lips", ParamColor("Lips's Color",colorGreen),
ParamStyle("Lips's Style", styleThick));

_SECTION_END();


_SECTION_BEGIN("BW Fractal");

UpFractal=
ValueWhen(
  (
Ref(H,-2) > Ref(H, -4)) AND
  (
Ref(H,-2) > Ref(H, -3)) AND
  (
Ref(H,-2) > Ref(H, -1)) AND
  (
Ref(H,-2) > H), Ref(H,-2));

DownFractal=
ValueWhen(
  (
Ref(L,-2) <= Ref(L, -4)) AND
  (
Ref(L,-2) <=  Ref(L, -3)) AND
  (
Ref(L,-2) <=  Ref(L, -1)) AND
  (
Ref(L,-2) <=  L), Ref(L,-2));



//== Added Crash  crashandburn59 [at] hotmail.com solution
Plot(Ref(UpFractal,2), "Up Fractal", ParamColor("Up Fractal Color",colorRed),
ParamStyle("Up Fractal Style", styleDashed));
Plot(Ref(DownFractal,2), "Down Fractal",ParamColor("Down Fractal
Color
",colorBlue), ParamStyle("Down Fractal Style", styleDashed));

//Plot(Max(HHV(H,3),Ref(UpFractal,2)), "Up Fractal", ParamColor("Up Fractal
Color
",colorRed), ParamStyle("Up Fractal Style", styleDashed));
//Plot(Max(HHV(H,3),Ref(UpFractal,2)), "Down Fractal",ParamColor("Down Fractal
Color
",colorBlue), ParamStyle("Down Fractal Style", styleDashed));

_SECTION_END();


Cheers,

Asis






__._,_.___


**** 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

__,_._,___