Please Help me to complete this script in PI

Buy when the price breaks Yesterday’s (previous day’s) High

Short when the price breaks Yesterday’s (previous day’s) Low

As per the above query use daily time frame

Buy Script:

LAST>REF(HIGH,1)

Sell Script:

LAST < REF(LOW,1)