DEA:=EMA(DIFF,9);
● Golden fork: = cross (diff, DEA) and diff.
JCCOUNT:=COUNT(CROSS(DIFF,DEA),bars last(DEA & gt; =0));
Quadratic golden fork: = cross (diff, DEA) and DEA < 0 AND COUNT(JCCOUNT=2 = 2,21) =1;
a 1:= bars last(REF(CROSS(DIFF,DEA), 1));
Bottom deviation: = ref (close, a1+1) > close and diff > REF(DIFF, A 1+ 1) and CROSS(DIFF, DEA);
● The gold fork and the secondary gold fork deviate from the bottom;