Skip to main content

Vertical Horizontal Filter for Amibroker (AFL)

mahesh.aranake about 16 years ago Amibroker (AFL)

  • Rating:
    4 / 5 (Votes 2)
  • Tags:
    amibroker, trend

This is amibroker for vertical horizontal filter which is useful to determine whether prices tend to trend (rising values) or moving towards trading / congestion zone (falling values)

Indicator / Formula

Copy & Paste Friendly
_SECTION_BEGIN("VHF");
pds=9; 
smooth=3;
hcp=HHV(C,pds);
lcp=LLV(C,pds);
mcp=C-Ref(C,-1);
sav=Sum(abs(mcp),pds);  

Vhf=(Hcp-Lcp)/sav;
Plot(EMA(vhf,smooth),"Vertical Horizontal Filter",colorBlue,4); 

Title=WriteIf(Vhf>Ref(Vhf,-1)AND
Ref(Vhf,-1)>Ref(Vhf,-2),EncodeColor(colorGreen)+" VHF is currently
rising.",EncodeColor(colorYellow)+" VHF is Falling."); 
_SECTION_END();

0 comments

Leave Comment

Please login here to leave a comment.