Author Topic: How to look at my last signal and take a decision in future  (Read 1011 times)

tiasamik

  • Newbie
  • *
  • Posts: 1
    • View Profile
How to look at my last signal and take a decision in future
« on: December 12, 2017, 03:23:58 am »
I was trying to implement stochastics cross as a signal along with when stochK cross 20. I wrote AFL like -

///
Buy=cross(stochk(15,2),stochD(15,2,2)) and stochk(15,2)>20;
///

This has a problem. above AFL provides signal only when StochK value is greater than 20 and a Stchk StchD cross is happening. But it can not work when a cross of stochK & stochD happens below 20 and after few bars stochK increases and cross 20. I want to get signal also, when cross of K & D is happening below 20 level and when stochK cross 20. can any one help?