Pi code for following

current close is higher(or lower) than previous 6 close