Problem regarding AlgO code of MACD Histogram

Hi:
I want to know whether Algo code for “MACD Histogram” is possible in Tradescript or not ?
If yes, then I want Algo code for MACD Histogram for the following strategy in Daily chart

Volume is “Greater than” 3 Days Simple Moving Average of Daily Volume,
MACD Histogram before 3 days is “Lesser than” MACD Histogram before 4 Days,
MACD Histogram before 2 days is “Greater than” MACD Histogram before 3 Days,

Please send the Tradescript Pi code for the above strategy