PureBytes Links
Trading Reference Links
|
I've plotted the indicator below on a Euro/USD 1-min chart, but can't
see any problems.
---8<---------------------------------
pds:=Input("Normalizing lookback pds
(1= historical Hi/Lo)",1,2600,150);
{ Plot 1: Price section }
PriceX:=C;
{ Plot 2: Indicator/Oscillator section }
IndX:=WillA();
{ Choose x pds or historical Price High/Low }
Hi:=If(pds>1,HHV(PriceX,pds),Highest(PriceX));
Lo:=If(pds>1,LLV(PriceX,pds),Lowest(PriceX));
{ Price normalized to 0~100% }
PriceNorm:=(PriceX-Lo)/Max(Hi-Lo,.000001)*100;
{ Choose x pds or historical Indicator High/Low}
Hi:=If(pds>1,HHV(IndX,pds),Highest(IndX));
Lo:=If(pds>1,LLV(IndX,pds),Lowest(IndX));
{ Indicator normalized to 0~100% }
IndicatorNorm:=(IndX-Lo)/Max(Hi-Lo,.000001)*100;
{ Plot in own window }
{PriceNorm;IndicatorNorm}
(IndicatorNorm-PriceNorm)/25
---8<---------------------------------
jose '-)
http://www.metastocktools.com
--- In equismetastock@xxxxxxxxxxxxxxx, stinkerstock <no_reply@xxx>
wrote:
>
> Dear Jose:
>
> A while back you provided me with a formula to convert the Williams
> A/D study into an oscillator. It went like this:
>
> pds:=Input("Normalizing lookback periods (1= historical
> Hi/Lo)",1,2600,150);
> { Plot 1: Price section }
> PriceX:=C;
> { Choose x pds or historical Price High/Low }
> Hi:=If(pds>1,HHV(PriceX,pds),Highest(PriceX));
> Lo:=If(pds>1,LLV(PriceX,pds),Lowest(PriceX));
> { Price normalized to 0~100% }
> PriceNorm:=(PriceX-Lo)/Max(Hi-Lo,.000001)*100;
> { Plot 2: Indicator/Oscillator section }
> IndX:=WillA();
> { Choose x pds or historical Indicator High/Low}
> Hi:=If(pds>1,HHV(IndX,pds),Highest(IndX));
> Lo:=If(pds>1,LLV(IndX,pds),Lowest(IndX));
> { Indicator normalized to 0~100% }
> IndicatorNorm:=(IndX-Lo)/Max(Hi-Lo,.000001)*100;
> { Plot in own window }
> {PriceNorm;IndicatorNorm}
> (IndicatorNorm-PriceNorm)/25
>
> This works perfectly on daily data but, for some reason, when I use
> the formula in explorer to sift through intrday data I always get an
> overflow error message. I've tried to modify it but nothing seems
> to work. Any chance you could help again?
>
> Thanks in advance,
>
> Jim
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/equismetastock/
<*> To unsubscribe from this group, send an email to:
equismetastock-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|