Value greater than yesterday scan?

dinodotcom

Member
2019 Donor
How do I code into a scan that I wish that value "x" is greater than yesterday? For example, I want to make sure that ADX value today is greater than yesterday?
 

_Merch_Man_

Member
Use the index function [y] where y is the number of bars back you want to go. So on a daily chart, to test is ADX today > ADX yesterday it would be:

Code:
ADX(14,AVERAGETYPE.SIMPLE) > ADX(14,AVERAGETYPE.SIMPLE)[1]
 
Top