PureBytes Links
Trading Reference Links
|
Tomasz,
I tried that (see last paragraph of original message), but then the
indicator doesn't plot as a histogram. It plots all lines from the
bottom of the pane. The only way I can get it to plot as a histogram
is if I remove the Logarithmic check box and I don't want to do that.
I want price plotted using Logarithmic scale.
Thanks for the lightning fast response.
Tim Gadd
--- In amibroker@xxxxxxxxxxxxxxx, "Tomasz Janeczko" <amibroker@xxxx>
wrote:
> Hello,
>
> There is no styleLog anymore.
> Use "logarithmic" check box in the Indicator Builder instead.
>
>
> Plot (RelRocOfPrice, "RelRoc of Price", barcolor, styleOwnScale |
styleHistogram); // don't use styleLog
>
> Best regards,
> Tomasz Janeczko
> amibroker.com
> ----- Original Message -----
> From: "Tim Gadd" <timgadd@xxxx>
> To: <amibroker@xxxxxxxxxxxxxxx>
> Sent: Monday, March 10, 2003 5:56 PM
> Subject: [amibroker] Indicator Code not working after upgrade
>
>
> > Prior to upgrading to version 4.3, the following code worked. Now
I'm
> > getting the error message ...
> >
> > Unknown identifier at line 29, column 10:
> > Plot (RelRocOfPrice, "RelRoc of Price", barcolor, styleLog |
> > -----------------------------------------------------------^
> >
> > BTW, this indicator code is placed in the builtin price indicator
> > formula.
> >
> > //Start of indicator code
> >
> > Period = 107;
> >
> > UpDay = C > Ref(C,-1);//define an up day
> > UpDays = Sum(UpDay, Period);//# of up days in the period
> > AvgUpRoc = MA(ROC(C,1) * UpDay,UpDays);//Average of the 1-day
ROCs
> > for up days over the lookback period
> > RelUpRoc = ROC(C,1) / Ref(AvgUpRoc,-1);//Today's 1-Day ROC
compared
> > to yesterday's AvgUpRoc
> > DnDay = C < Ref(C,-1);//define a down day
> > DnDays = Sum(DnDay, Period);//# of down days in the period
> > AvgDnRoc = MA(ROC(C,1) * DnDay,DnDays);//Average of the 1-day
ROCs
> > for down days over the lookback period
> > RelDnRoc = -(ROC(C,1) / Ref(AvgDnRoc,-1));//Today's 1-Day ROC
> > compared to yesterday's AvgDnRoc
> >
> > RelRocOfPrice = IIf(UpDay,RelUpRoc-1,RelDnRoc+1);
> >
> > BarColor = IIf(UpDay, colorDarkGreen, IIf(DnDay,
> > colorRed,colorBlack) );
> >
> > Plot (RelRocOfPrice, "RelRoc of Price", barcolor, styleLog |
> > styleOwnScale | styleHistogram); // THIS IS THE PROBLEM LINE
> >
> > Plot(MA(RelRocOfPrice,3),"",colorLightBlue,styleHistogram |
> > styleThick | styleOwnScale);
> >
> > //--Indicator-End--
> >
> > If I remove the styleLog parameter from the problem line, the
error
> > message goes away, but the indicator no longer plots as a
histogram.
> > It plots all lines starting from the bottom of the pane. I have
> > Logarithmic checked at the bottom of the indicator builder, as I
want
> > to price plotted using a logarithmic scale.
> >
> > Can someone spot the problem? Help appreciated.
> >
> > Tim Gadd
> >
> >
> >
> >
> > Send BUG REPORTS to bugs@xxxx
> > Send SUGGESTIONS to suggest@xxxx
> > -----------------------------------------
> > Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
> > (Web page: http://groups.yahoo.com/group/amiquote/messages/)
> > --------------------------------------------
> > Check group FAQ at:
http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> >
> > Your use of Yahoo! Groups is subject to
http://docs.yahoo.com/info/terms/
> >
> >
> >
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
|