MetaStock™ Zone Forum & FAQ Artykuły Linki Elliott Waves EasyLanguage™ Zone

 A B C D E F G H I J K L M N O P R S T U V W Y Z #

A simple exploration filter formula for finding a bullish divergence between
the RSI and the price is shown below. To find a bearish divergence, replace > with <. The differences in the trough function was found through an optimization routine and they may not be the best values for your application.

ColA:
Name: Close

CLOSE

ColB:
Name: KST

(Mov(ROC(C,10,%),10,S)*1)+(Mov(ROC(C,15,%),10,S)*2)+
(Mov(ROC(C,20,%),10,S)*3)+(Mov(ROC(C,30,%),15,S)*4)

ColC:
Name: KST MA

Mov((Mov(ROC(C,10,%),10,S)*1)+(Mov(ROC(C,15,%),10,S)*2)+
(Mov(ROC(C,20,%),10,S)*3)+(Mov(ROC(C,30,%),15,S)*4),10,S)

ColD:
Name: KST-1

Ref( (Mov(ROC(C,10,%),10,S)*1)+(Mov(ROC(C,15,%),10,S)*2)+
(Mov(ROC(C,20,%),10,S)*3)+(Mov(ROC(C,30,%),15,S)*4),-1)

ColE:
Name: MA KST-1

Ref(Mov((Mov(ROC(C,10,%),10,S)*1)+(Mov(ROC(C,15,%),10,S)*2)+
(Mov(ROC(C,20,%),10,S)*3)+(Mov(ROC(C,30,%),15,S)*4),10,S),-1)

Filter:
When(colB,>,colC)AND When(colB,<,0)AND When( colD,<,colE)

Source / From: TOP