Hi Guys
what wrong with the code below? all I am after is a MACD and Stoch crossover at the same time.
indicator1 = SmoothedStochastic[14,3](close)
c1 = (indicator1 CROSSES OVER 0)
indicator2 = ExponentialAverage[9](MACDline[12,26,9](close))
indicator3 = MACDline[12,26,9](close)
c2 = (indicator2 CROSSES OVER indicator3)
SCREENER[c1 AND c2] (null AS "null")
Cheers
Andrew
To write code, please use the <> “insert PRT code” button, to make code easier to read.
Thank you.
It’s because STOCHASTIC cannot be < 0, so there will never be a CROSSOVER (line 2).