Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 1

// Downloaded From www.WiseStockTrader.

com
_SECTION_BEGIN("ATR Levels");

iATRPeriod = Param("ATRPeriod", 4, 1, 10, 1);


dATRLevel = Param("ATRLevel", 1, 0.25, 2, 0.25);

TimeFrameSet(inMonthly); // go to monthly chart


monthATR = Ref(ATR(iATRPeriod), 0); // ATR value
monthClose = Ref(Close, 0); // close of last month
TimeFrameRestore(); // go back to origin timeframe

ATRM_S1 = MonthClose - dATRLevel * monthATR;


ATRM_R1 = MonthClose + dATRLevel * monthATR;

expCloseM = TimeFrameExpand(monthClose, inMonthly, expandLast);


Plot(expCloseM, "ATR Month Middle", colorLightBlue, styleLine );

expATRM_S1 = TimeFrameExpand(ATRM_S1, inMonthly, expandLast);


Plot(expATRM_S1, "ATR Month Support", colorGreen, styleDashed );

expATRM_R1 = TimeFrameExpand(ATRM_R1, inMonthly, expandLast);


Plot(expATRM_R1, "ATR Month Resistance", colorRed, styleDashed );

_SECTION_END();

You might also like