# Formula for Darvas box system?



## porkpie324 (1 July 2006)

Hello all, does anyone know where I can get the formula for the "darvas box" system? My software is Metastock 9.1, porkpie


----------



## tech/a (1 July 2006)

This is the original Darvas box formula:
LL:=If(L=LLV(L,5),L,If(Ref(L,-1)=LLV(L,5),Ref(L,-1),If(Ref(L,-2)=LLV(L,5),Ref(L,-2),If(Ref(L,-3)=LLV(L,5),Ref(L,-3),If(Ref(L,-4)=LLV(L,5),Ref(L,-4),0)))));

NH:=ValueWhen(1,H>Ref(HHV(H,5),-1),H);

Set1:=HHV(H,3)<HHV(H,4);

Val1:=ValueWhen(1,BarsSince(H>Ref(HHV(H,5),-1))=3 AND Set1=true,NH);

Val2:=ValueWhen(1,BarsSince(H>Ref(HHV(H,5),-1))=3 AND Set1=true,LL);


TB:=Val1;
BB:=Val2;


----------

