Amibroker Afl Collection Guide
You can save it as MTF_Trend_Momentum.afl .
// RSI in separate window rsiColor = IIf(LTF_RSI > RSIOverbought, colorRed, IIf(LTF_RSI < RSIOversold, colorGreen, colorLightGrey)); Plot(LTF_RSI, "RSI (" + RSIPeriod + ")", rsiColor, styleLine | styleThick); Plot(RSIOverbought, "OB", colorRed, styleDashed); Plot(RSIOversold, "OS", colorGreen, styleDashed);
Short = SellSignal; // Example short logic Cover = BuySignal; amibroker afl collection
// Optional: Exit signals Buy = ExRem(BuySignal, SellSignal); Sell = ExRem(SellSignal, BuySignal);
// ----------------------------------------------------------- // SCAN / EXPLORATION OUTPUT (for AA Window) // ----------------------------------------------------------- Filter = Buy OR Sell; AddColumn(C, "Close", 1.2); AddColumn(LTF_RSI, "RSI", 1.2); AddColumn(HTF_RSI_Exp, "HTF RSI", 1.2); AddColumn(IIf(Buy, "BUY", IIf(Sell, "SELL", "")), "Signal", 1.0); You can save it as MTF_Trend_Momentum
// ----------------------------------------------------------- // USER INPUTS // ----------------------------------------------------------- TF1 = ParamTimeFrame("Higher Timeframe", "Weekly"); TF2 = ParamTimeFrame("Lower Timeframe", "Daily");
// Lower Timeframe MA Plot(LTF_MA, "LTF MA", colorYellow, styleLine | styleDots); "RSI (" + RSIPeriod + ")"
// ----------------------------------------------------------- // PLOTTING // ----------------------------------------------------------- Plot(C, "Price", colorWhite, styleCandle);