@tomsk Sorry Im looking for an alert as to when the arrows show up example buy sell here is the scriptI appreciate any help:
input price = hl2;
input superfast_length = 8;#5
input fast_length = 13;#8
input slow_length = 13;#13
input jawDisplace = -8;#-8
input teethDisplace = -5;#-5
input lipsDisplace = -3;#-3
input averageType = AverageType.WILDERS;
def mov_avg5 = MovingAverage(averageType, price[-lipsDisplace], superfast_length);
def mov_avg8 = MovingAverage(averageType, price[-teethDisplace], fast_length);
def mov_avg13 = MovingAverage(averageType, price[-jawDisplace], slow_length);
#moving averages
Plot Superfast = mov_avg5;
Superfast.SetLineWeight(2);
plot Fast = mov_avg8;
#Fast.SetStyle(Curve.short_DASH);
Fast.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);
Fast.SetLineWeight(3);
plot Slow = mov_avg13;
Slow.SetLineWeight(2);
Superfast.SetDefaultColor(Color.GREEN);
Fast.SetDefaultColor(Color.RED);
Slow.SetDefaultColor(Color.BLUE);
DefineGlobalColor("Bullish", Color.BLUE);
DefineGlobalColor("Bearish", Color.MAGENTA);
AddCloud(Superfast, Fast, globalColor("Bullish"), globalColor("Bearish"));
def buy = mov_avg5 > mov_avg8 and mov_avg8 > mov_avg13 and low > mov_avg5;
def stopbuy = mov_avg5 <= mov_avg8;
def buynow = !buy[1] and buy;
def buysignal = CompoundValue(1, if buynow and !stopbuy then 1 else if buysignal[1]==1 and stopbuy then 0 else buysignal[1], 0);
plot Buy_Signal = buysignal[1] == 0 and buysignal==1;
Buy_signal.setpaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
Buy_signal.setdefaultColor(color.dark_GREEN);
Buy_signal.hidetitle();
#Alert(condition = buysignal[1] == 0 and buysignal == 1, text = "Buy Signal", sound = Sound.Bell, "alert type" = Alert.BAR);
plot Momentum_Down = buysignal[1] ==1 and buysignal==0;
Momentum_down.setpaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_DOWN);
Momentum_Down.setdefaultColor(color.yellow);
Momentum_down.hidetitle();
#Alert(condition = buysignal[1] == 1 and buysignal == 0, text = "Momentum_Down", sound = Sound.Bell, "alert type" = Alert.BAR);
def sell = mov_avg5 < mov_avg8 and mov_avg8 < mov_avg13 and high < mov_avg5;
def stopsell = mov_avg5 >= mov_avg8;
def sellnow = !sell[1] and sell;
def sellsignal = CompoundValue(1, if sellnow and !stopsell then 1 else if sellsignal[1]==1 and stopsell then 0 else sellsignal[1], 0);
Plot Sell_Signal = sellsignal[1] ==0 and sellsignal;
Sell_signal.setpaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_down);
sell_signal.setDefaultColor(color.red);
Sell_signal.hidetitle();
#Alert(condition = sellsignal[1] == 0 and sellsignal == 1, text = "Sell Signal", sound = Sound.Bell, "alert type" = Alert.BAR);
Plot Momentum_Up = sellsignal[1]==1 and sellSignal==0;
Momentum_up.setpaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_up);
Momentum_up.setDefaultColor(color.yellow);
Momentum_up.hidetitle();
#Alert(condition = sellsignal[1] == 1 and sellSignal == 0, text = "Momentum_Up", sound = Sound.Bell, "alert type" = Alert.BAR);
#plot Colorbars = if buysignal ==1 then 1 else if sellsignal ==1 then 2 else if buysignal ==0 or sellsignal==0 then 3 else 0;
#colorbars.hide();
#Colorbars.definecolor("Buy_Signal_Bars", color.dark_green);
#Colorbars.definecolor("Sell_Signal_Bars", color.red);
#Colorbars.definecolor("Neutral", color.yellow);
#AssignPriceColor(if Colorbars ==1 then colorbars.color("buy_signal_bars") else if colorbars ==2 then colorbars.color("Sell_Signal_bars") else colorbars.color("neutral"));
#end