// Downloaded From https://www.WiseStockTrader.com
_SECTION_BEGIN("4-DAY Down");
 

Day4Dn=C < Ref(C,-1) AND Ref(C,-1)<Ref(C,-2)AND Ref(C,-2)<Ref(C,-3) AND Ref(C,-3) < Ref(C,-4);
Buy = Day4Dn;
Sell = C<1;
Filter = C  AND C >2 AND Volume > 100000;

//Filter = Buy OR Sell;
Action = WriteIf(Buy, "BUY", WriteIf(Sell, "SELL", "   "));
Result = WriteIf(Buy,"Buy","Sell");
AddTextColumn( WriteIf(Buy, "Buy" , "Sell" ) ,   "TRADE" ,  5 ,   IIf(Buy,colorYellow, colorWhite), IIf(Buy, colorDarkGreen, colorRed) );
AddTextColumn(IndustryID(1) ,"Industry Sector  ", 25.0, colorWhite, colorBlue, 125);     // adds a column for the industry sector 
AddColumn(C, "Close", 3.2,  colorBlue, colorYellow, 55); 										// adds a column for today's close
AddColumn(Ref(Close,-1),"Y-Close",1.2, IIf( ROC(Ref(C,-1),1)>=0,colorDarkGreen, colorRed ),50 );
AddColumn( ROC( Close, 1 ), "ROC(1)", 1.2, IIf( ROC(C, 1 ) >= 0,colorDarkGreen, colorRed));					
//AddColumn(PCY, "% > Prior C" ,3.1, colorWhite,colorDarkGreen); 								// adds a column for the close as a % from the prior close
AddColumn(V, "VOLUME",8.0, colorYellow, colorDarkGreen, 75);									// adds a column for today's volume