// Downloaded From https://www.WiseStockTrader.com SetChartOptions(2,chartShowArrows|chartShowDates|chartWrapTitle); SetChartOptions(0,chartShowArrows|chartShowDates); //GfxGradientRect( 180, 30, 1759, 735, ColorRGB(40,40,40), ColorRGB(0,0,40) ); GfxSetOverlayMode(1); GfxSelectPen( ColorRGB(150,0,0), 1 ); GfxSelectSolidBrush( ColorRGB(0,0,40) ); GfxRectangle( 0,750, 1807, 35 ); GfxSelectPen( ColorRGB(150,0,0), 2 ); GfxSelectSolidBrush( ColorRGB(65,65,65) ); GfxPolygon(250,200,200,250,250,20,200,50); //GfxSelectPen( ColorRGB(125,0,0), 1 ); //GfxSelectSolidBrush( ColorRGB(0,0,40) ); //GfxRectangle( 10,100, 190, 160 ); GfxSelectPen( ColorRGB(0,0,0), 1 ); GfxSelectSolidBrush( ColorRGB(0,0,0) ); //GfxSetTextAlign( 250 );// center alignment GfxSetOverlayMode(1); GfxSelectFont("Times New Roman", 30, 400, True ); GfxSetTextColor( ColorRGB( 105, 105, 105 ) ); GfxSetBkMode(0); // transparent GfxTextOut("Pathfinder", 15 , 35 ); _SECTION_BEGIN("Flower"); si=Param("Zoom/In Out",5,-50,100,1); GraphXSpace=si; r1 = Param( "ColorFast avg", 5, 2, 200, 1 ); r2 = Param( "ColorSlow avg", 10, 2, 200, 1 ); r3 = Param( "ColorSignal avg", 5, 2, 200, 1 ); m1=MACD(r1,r2); s1=Signal(r1,r2,r3); mycolor=IIf(m1<0 AND m1>s1, ColorRGB(155,155,155),IIf(m1>0 AND m1>s1,ColorRGB(0,125,0),IIf(m1>0 AND m1Open,ColorRGB(0,245,0),ColorRGB(255,0,0)); //Ctmpl = E_TSKP_COLORTMPL(Open,High,Low,Close,Volume); total = 0; //total = total + IIf(tskp_colortmplcnd0 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd1 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd2 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd3 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd4 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd5 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd6 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd7 > 0, 1, -1); //total = total + IIf(tskp_colortmplcnd8 > 0, 1, -1); for( i = 0; i < BarCount; i++ ) { if( total[i] >= 5 ) Color[i] = colorLime; else if( total[i] <= -5 ) Color[i] = colorRed; else Color[i] = colorWhite; } Candle=ParamList("Candle","Modified Candlestick,Modified Heikin Ashi,Normal Candlestick",1); if(Candle=="Modified Candlestick") { ColorHighliter = myColor; SetBarFillColor( ColorHighliter ); Plot (Close,"- Modified Candlestick", Color,ParamStyle( "Style", styleCandle|styleLine | styleThick, maskAll)); } if(Candle=="Modified Heikin Ashi") { ColorHighliter = myColor; SetBarFillColor( ColorHighliter ); PlotOHLC( IIf(flowerOpen Ref(test,-1) AND Ref(test,1) < High;//Peak PKV0 = ValueWhen(PK,flowerHigh,0);//PeakValue0 PKV1 = ValueWhen(PK,flowerHigh,1);//PeakValue1 PKV2 = ValueWhen(PK,flowerHigh,2);//PeakValue2 MPK = PKV2 < PKV1 AND PKV1 > PKV0 ;//MajorPeak RsColor=ParamColor("ResistColor",ColorRGB(225,0,0)); BrCount=Param("ResistBarLength",8,1,500,1); for (i=0;i Low AND test2 < Ref(test2,-1);//Peak SPV0 = ValueWhen(SP,flowerLow,0);//PeakValue0 SPV1 = ValueWhen(SP,flowerLow,1);//PeakValue1 SPV2 = ValueWhen(SP,flowerLow,2);//PeakValue2 MSP = SPV2 > SPV1 AND SPV1 < SPV0 ;//MajorPeak SpColor=ParamColor("SupColor",ColorRGB(0,225,0)); BrCount=Param("SupBarLength",8,1,500,1); for (i=0;i0) AND (NewUpDown > 0) AND (UpDown7 > 0)),shapeSmallCircle,shapeNone), ColorRGB(0,125,255),0, Low, -8); PlotShapes( IIf( ((Combo<0) AND (NewUpDown < 0) AND (UpDown7 < 0)),shapeSmallCircle,shapeNone), ColorRGB(225,0,0),0, High, 8); } else { //PlotShapes( IIf( ((Combo>0) AND (NewUpDown > 0) AND (UpDown7 > 0)),shapeSmallCircle,shapeNone), ColorRGB(0,255,0),0, flowerlow, -12); //PlotShapes( IIf( ((Combo<0) AND (NewUpDown < 0) AND (UpDown7 < 0)),shapeSmallCircle,shapeNone), ColorRGB(255,0,0),0, flowerhigh, 12); } } _SECTION_END(); Title = StrFormat("\\c02 {{NAME}} | {{DATE}} | Open : %g | High : %g | Low : %g | Close : %g | Change = %.1f%% | Volume = " +WriteVal( V, 1.0 ) +", {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 )) ); _SECTION_BEGIN("TSKPPIVOT"); if(Candle=="Modified Heikin Ashi") { CHiPr = 0; CLoPr = 9999999; blsLong = 0; PrevCOBar = 0; NumBars = 0; PrePP = 0; PrevLowVal = 9999999; BuySig = 0; blsShort = 0; PrevHiVal = 0; blsNewCO = 0; BarDif = 0; //KPA900Val = E_TSKPA900(Close); //KPAutoStopVal = E_TSKPAUTOSTOP(High,Low,Close); // -- Create 0-initialized arrays the size of barcount aHPivs = flowerHigh - flowerHigh; aLPivs = flowerLow - flowerLow; aHiVal = flowerHigh - flowerHigh; aLoVal = flowerLow - flowerLow; //Ctmpl = E_TSKPCOLORTMPL(Open,High,Low,Close,Volume); sctotal = 0; //sctotal = sctotal + IIf(tskp_colortmplcnd0 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd1 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd2 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd3 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd4 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd5 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd6 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd7 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd8 > 0, 1, -1); for (curBar=0; curBar < BarCount-1; curBar++) { if ( curBar == 0 ) { CHiPr = flowerHigh[curBar]; CHiBar = curBar; CLoPr = flowerLow[curBar]; CLoBar = curBar; blsLong = 0; blsShort = 0; blsNewCO = 0; PrePP = 0; PrevCOBar = 0; PrevHiVal = flowerHigh[curBar]; PrevLowVal = flowerLow[curBar]; BuySig = 0; SellSig = 0; blsLL = 0; } if (flowerHigh[CurBar] >= CHiPr) { CHiPr = flowerHigh[CurBar]; ChiBar = CurBar; } if (flowerLow[CurBar] <= CLoPr) { CLoPr = flowerLow[CurBar]; CLoBar = CurBar; } //if ( (KPA900Val[curBar] >= KPAutoStopVal[curbar]) AND (PrePP != -1) AND (blsLong != 1) ){ BarDif = CurBar - PrevCOBar; if (BarDif >= NumBars) { blsLong = 1; blsShort = 0; blsNewCO = 1; PrevCOBar = CurBar; } } //if ( (KPA900Val[curBar] <= KPAutoStopVal[curbar]) AND (PrePP != 1) AND (blsShort != 1) ){ BarDif = CurBar - PrevCOBar; if (BarDif >= NumBars) { blsLong = 0; blsShort = 1; blsNewCO = 1; PrevCOBar = CurBar; } } if ( (blsNewCO == 1) AND (sctotal[CurBar] >= 5) AND (blsLong == 1) ) { LVal = CurBar - CLoBar; for (j= CLoBar-1; j <= CLoBar+1; j++) { if (j >=0) { aLPivs[j] = 1; aLoVal[j] = CLoPr; } } PrePP = -1; blsNewCO = 0; CHiPr = flowerHigh[CurBar]; CHiBar = CurBar; CLoPr = flowerLow[Curbar]; CLoBar = CurBar; } // else if ((blsNewCO == 1) AND (sctotal[CurBar] <= -5) AND (blsShort == 1) ) { HVal = CurBar - CHiBar; for (j= CHiBar-1; j <= CHiBar+1; j++) { if (j >=0) { aHPivs[j] = 1; aHiVal[j] = CHiPr; } } PrePP = 1; blsNewCO = 0; CHiPr = flowerHigh[CurBar]; CHiBar = CurBar; CLoPr = flowerLow[Curbar]; CLoBar = CurBar; //} //} PlotShapes(IIf(aHPivs == 1, 21,shapeNone), ColorRGB(255,0,145),0, aHiVal,Offset = 20); PlotShapes(IIf(aHPivs == 1, 15,shapeNone), ColorRGB(200,50,75),0, aHiVal,Offset = 20); PlotShapes(IIf(aLPivs == 1, 21,shapeNone), ColorRGB(0,125,225),0, aLoVal, Offset = -20); PlotShapes(IIf(aLPivs == 1, 15,shapeNone), ColorRGB(0,125,255),0, aLoVal, Offset = -20); //} _SECTION_END(); _SECTION_BEGIN("TSKPMoMo"); if(Candle=="Modified Heikin Ashi") { blsLong = 0; //KPStopLine = E_TSKPSTOPLINE(High,Low,Close); // tskp_upsell, tskp_triggerline, tskp_triggerlinevma //sw = E_TSKPUPSELL(Open,High,Low,Close,Volume); //KPTriggerLine = tskp_triggerline; //KPFast3Val = IIf((E_TSKPFAST3(Open,High,Low,Close,Volume)> 0),1, -1); //tskp_fast2val1, tskp_fast2val2 //dummy = E_TSKPFAST2(Open,High,Low,Close,Volume); //KPFast2Val = IIf ((tskp_fast2val1 > 0),1,-1); //Ctmpl = E_TSKPCOLORTMPL(Open,High,Low,Close,Volume); sctotal = 0; //sctotal = sctotal + IIf(tskp_colortmplcnd0 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd1 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd2 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd3 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd4 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd5 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd6 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd7 > 0, 1, -1); //sctotal = sctotal + IIf(tskp_colortmplcnd8 > 0, 1, -1); // tskp_mediumma,tskp_mediumup,tskp_mediumdown //dummy = E_TSKPMEDIUM(Close); //KPMediumUP = tskp_mediumup; //KPMediumDwn = tskp_mediumdown; //KPMediumMA = tskp_mediumma; // -- Create 0-initialized arrays the size of barcount aHPivs = H - H; aLPivs = L - L; aHiVal = H - H; aLoVal = L - L; for (curBar=5; curBar < BarCount-1; curBar++) { if( (blsLong == -1) OR (blsLong == 0)) { if ((sctotal[CurBar] >= 5) AND (KPMediumUP[CurBar] > KPMediumMA[CurBar] ) AND (KPFast3Val[CurBar] == 1) AND (KPFast2Val[CurBar] == 1) AND (KPTriggerLine[CurBar] >= KPStopLine[CurBar] )) { blsLong = 1; aLPivs[CurBar] = 1; aLoVal[CurBar] = Low[CurBar]; } } if( (blsLong == 1) OR (blsLong == 0)) { if ((sctotal[CurBar] <= -5) AND (KPMediumDwn[CurBar] < KPMediumMA[CurBar] ) AND (KPFast3Val[CurBar] == -1) AND (KPFast2Val[CurBar] == -1) AND (KPTriggerLine[CurBar] <= KPStopLine[CurBar] )) { blsLong = -1; aHPivs[Curbar] = 1; aHiVal[Curbar] = High[Curbar]; } } if ((blsLong == 1) AND ((sctotal[CurBar] < 5) OR (KPMediumUP[CurBar] < KPMediumMA[CurBar] ) OR (KPFast2Val[CurBar] < 1) OR (KPFast3Val[CurBar] < 1) OR (KPTriggerLine[CurBar] < KPStopLine[CurBar] )) ) { blsLong= 0; } if ((blsLong == -1) AND ((sctotal[CurBar] > -5) OR (KPMediumDwn[CurBar] > KPMediumMA[CurBar] ) OR (KPFast2Val[CurBar] > -1) OR (KPFast3Val[CurBar] > -1) OR (KPTriggerLine[CurBar] > KPStopLine[CurBar] )) ) { blsLong = 0; } } PlotShapes (IIf(aHPivs == 1, shapeHollowSmallSquare, shapeNone) ,colorRed, layer = 0, yposition = flowerHigh, offset = 12 ); PlotShapes (IIf(aLPivs == 1, shapeHollowSmallSquare, shapeNone) ,colorLime, layer = 0, yposition = flowerLow, offset = -12 ); } _SECTION_END(); _SECTION_BEGIN("TSKPEBand"); /* Standard Error Bands */ Periods = Param("Standard Error", 20, 3, 200, 1); Smooth = Param("Smooth",12,2,100,1); LRCurve = LinearReg( C, periods ); MALRCurve = MA(LRCurve, Smooth); SEValue = StdErr( C, periods ); SErrorAvg = MA(SEValue, Smooth); LowerBand = MALRCurve - SErrorAvg ; UpperBand = MALRCurve + SErrorAvg ; Plot( MALRCurve , "MidBand", ParamColor("ColorMB",ColorRGB(0,200,0)) , ParamStyle("StyleMB", style=styleDashed, Mask=maskDefault )); Plot( UpperBand , "UpperBand", ParamColor("ColorUp",colorTeal) , ParamStyle("StyleUp", style=styleDashed, Mask=maskDefault )); Plot( LowerBand , "LowerBand", ParamColor("ColorLo",colorTeal), ParamStyle("StyleLo", style=styleDashed, Mask=maskDefault )); _SECTION_END(); _SECTION_BEGIN("Cloud Setting"); //Cloud ParmCloud = ParamToggle("Cloud", "No|Yes", 1); CloudResColor=ParamColor("CloudResColor",ColorRGB(15,15,15)); CR=Upperband; CS=Lowerband; if(parmCloud == 1) { PlotOHLC( CS, CS, CR,CR, "Band", CloudResColor, styleCloud | styleNoLabel|styleNoTitle); } _SECTION_END(); _SECTION_BEGIN("KPL Swing"); //Copyright Kamalesh Langote. Email:kpl@vfmdirect.com. More details at http://www.vfmdirect.com/kplswing //Save indicator as "kplswing.afl" in C: program files > Amibroker > Formulas > Custom folder and then drap and drop on price chart no=Param( "Swing", 20, 1, 55 ); tsl_col=ParamColor( "Color", colorCycle ); res=HHV(H,no); sup=LLV(L,no); avd=IIf(C>Ref(res,-1),1,IIf(CRef(res,-1),1,IIf(C1;i--) { if(Buy[i] == 1) { entry = C[i]; sig = "BUY"; sl = s5d[i]; tar1 = entry + (entry * .0050); tar2 = entry + (entry * .0092); tar3 = entry + (entry * .0179); bars = i; i = 0; } if(Sell[i] == 1) { sig = "SELL"; entry = C[i]; sl = s5d[i]; tar1 = entry - (entry * .0050); tar2 = entry - (entry * .0112); tar3 = entry - (entry * .0212); bars = i; i = 0; } } Offset = 20; Clr = IIf(sig == "BUY", colorLime, colorRed); ssl = IIf(bars == BarCount-1, s5d[BarCount-1], Ref(s5d, -1)); sl = ssl[BarCount-1]; Plot(LineArray(bars-Offset, tar1, BarCount, tar1,1), "", Clr, styleLine|styleDots, Null, Null, Offset); Plot(LineArray(bars-Offset, tar2, BarCount, tar2,1), "", Clr, styleLine|styleDots, Null, Null, Offset); Plot(LineArray(bars-Offset, tar3, BarCount, tar3,1), "", Clr, styleLine|styleDots, Null, Null, Offset); Plot(LineArray(bars-Offset, sl, BarCount, sl,1), "", colorDarkRed, styleLine|styleLine, Null, Null, Offset); Plot(LineArray(bars-Offset, entry, BarCount, entry,1), "", colorGreen, styleLine|styleLine, Null, Null, Offset); for (i=bars; i Sp2,ParamColor("Span1 Color", ColorRGB(0,255,0)),ParamColor("Span2 Color",ColorRGB(255,104,32))),styleCloud); _SECTION_END(); /////////////////////////////////////Kpl Swing ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //kpl swing formula here //---- heikin ashi HaClose = (O+H+L+C)/4; HaOpen = AMA( Ref( HaClose, -1 ), .40); HaHigh = Max( H, Max( HaClose, HaOpen ) ); HaLow = Min( L, Min( HaClose, HaOpen ) ); xDiff = (HaHigh - Halow) * IIf(StrFind(Name(),"JPY"),100,10000); // Plot(EMA(HaClose,9),"",colorWhite, styleLine); // Plot(EMA(HaClose,18),"",colorBlack, styleLine); _SECTION_BEGIN("KPL Swing"); no=Param( "Swing", 10, 1, 55 ); tsl_col=ParamColor( "Color", colorCycle ); res=HHV(H,no); sup=LLV(L,no); avd=IIf(C>Ref(res,-1),1,IIf(CC); } else if(P == 2) { PatternName = "LongBlackCandle"; Pv = (O>C AND (O-C)/(.001+H-L)>.6); } else if(P == 3) { PatternName = "SmallBlackCandle"; Pv = ((O>C) AND ((H-L)>(3*(O-C)))); } else if(P == 4) { PatternName = "WhiteCandle"; Pv = (C>O); } else if(P == 5) { PatternName = "LongWhiteCandle"; Pv = ((C>O) AND ((C-O)/(.001+H-L)>.6)); } else if(P == 6) { PatternName = "SmallWhiteCandle"; Pv = ((C>O) AND ((H-L)>(3*(C-O)))); } else if(P == 7) { PatternName = "BlackMaubozu"; Pv = (O>C AND H==O AND C==L); } else if(P == 8) { PatternName = "WhiteMaubozu"; Pv = (C>O AND H==C AND O==L); } else if(P == 9) { PatternName = "BlackClosingMarubozu"; Pv = (O>C AND C==L); } else if(P == 10) { PatternName = "WhiteClosingMarubozu"; Pv = (C>O AND C==H); } else if(P == 11) { PatternName = "BlackOpeningMarubozu"; Pv = (O>C AND O==H); } else if(P == 12) { PatternName = "WhiteOpeningMarubozu"; Pv = (C>O AND O==L); } else if(P == 13) { PatternName = "HangingMan"; Pv = (((H-L)>4*(O-C)) AND ((C-L)/(.001+H-L)>= 0.75) AND ((O-L)/(.001+H-L)>= 0.75)); } else if(P == 14) { PatternName = "Hammer"; Pv = (((H-L)>3*(O-C)) AND ((C-L)/(.001+H-L)>0.6) AND ((O-L)/(.001+H-L)>0.6)); } else if(P == 15) { PatternName = "InvertedHammer"; Pv = (((H-L)>3*(O-C)) AND ((H-C)/(.001+H-L)>0.6) AND ((H-O)/(.001+H-L)>0.6)); } else if(P == 16) { PatternName = "ShootingStar"; Pv = (((H-L)>4*(O-C)) AND ((H-C)/(.001+H-L)>= 0.75) AND ((H-O)/(.001+H-L)>= 0.75)); } else if(P == 17) { PatternName = "BlackSpinningTop"; Pv = ((O>C) AND ((H-L)>(3*(O-C))) AND (((H-O)/(.001+H-L))<.4) AND (((C-L)/(.001+H-L))<.4)); } else if(P == 18) { PatternName = "WhiteSpinningTop"; Pv = ((C>O) AND ((H-L)>(3*(C-O))) AND (((H-C)/(.001+H-L))<.4) AND (((O-L)/(.001+H-L))<.4)); } else if(P == 19) { PatternName = "BearishAbandonedBaby"; Pv = ((C1 == O1) AND (C2>O2) AND (O>C) AND (L1>H2) AND (L1>H)); } else if(P == 20) { PatternName = "BearishEveningDojiStar"; Pv = ((C2>O2) AND ((C2-O2)/(.001+H2-L2)>.6) AND (C2O1) AND ((H1-L1)>(3*(C1-O1))) AND (O>C) AND (OO1 AND ((C1+O1)/2)>C AND O>C AND O>C1 AND C>O1 AND (O-C)/(.001+(H-L)>0.6)); } else if(P == 22) { PatternName = "BearishEngulfing"; Pv = ((C1>O1) AND (O>C) AND (O>= C1) AND (O1>= C) AND ((O-C)>(C1-O1))); } else if(P == 23) { PatternName = "ThreeOutsideDownPattern"; Pv = ((C2>O2) AND (O1>C1) AND (O1>= C2) AND (O2>= C1) AND ((O1-C1)>(C2-O2)) AND (O>C) AND (CC2) AND (C>O) AND (L2>H1) AND (L>H1)); } else if(P == 25) { PatternName = "BullishMorningDojiStar"; Pv = ((O2>C2) AND ((O2-C2)/(.001+H2-L2)>.6) AND (C2>O1) AND (O1>C1) AND ((H1-L1)>(3*(C1-O1))) AND (C>O) AND (O>O1)); } else if(P == 26) { PatternName = "BullishEngulfing"; Pv = ((O1>C1) AND (C>O) AND (C>= O1) AND (C1>= O) AND ((C-O)>(O1-C1))); } else if(P == 27) { PatternName = "ThreeOutsideUpPattern"; Pv = ((O2>C2) AND (C1>O1) AND (C1>= O2) AND (C2>= O1) AND ((C1-O1)>(O2-C2)) AND (C>O) AND (C>C1)); } else if(P == 28) { PatternName = "BullishHarami"; Pv = ((O1>C1) AND (C>O) AND (C<= O1) AND (C1<= O) AND ((C-O)<(O1-C1))); } else if(P == 29) { PatternName = "ThreeInsideUpPattern"; Pv = ((O2>C2) AND (C1>O1) AND (C1<= O2) AND (C2<= O1) AND ((C1-O1)<(O2-C2)) AND (C>O) AND (C>C1) AND (O>O1)); } else if(P == 30) { PatternName = "PiercingLine"; Pv = ((C10.6)); } else if(P == 31) { PatternName = "BearishHarami"; Pv = ((C1>O1) AND (O>C) AND (O<= C1) AND (O1<= C) AND ((O-C)<(C1-O1))); } else if(P == 32) { PatternName = "ThreeInsideDownPattern"; Pv = ((C2>O2) AND (O1>C1) AND (O1<= C2) AND (O2<= C1) AND ((O1-C1)<(C2-O2)) AND (O>C) AND (CO*1.01) AND (C1>O1*1.01) AND (C2>O2*1.01) AND (C>C1) AND (C1>C2) AND (OO1) AND (O1O2) AND (((H-C)/(H-L))<.2) AND (((H1-C1)/(H1-L1))<.2) AND (((H2-C2)/(H2-L2))<.2); } else if(P == 34) { PatternName = "DarkCloudCover"; Pv = (C1>O1*1.01) AND (O>C) AND (O>H1) AND (C>O1) AND (((C1+O1)/2)>C) AND (C>O1) AND (MA(C,13)-Ref(MA(C,13),-4)>0); } else if(P == 35) { PatternName = "ThreeBlackCrows"; Pv = (O>C*1.01) AND (O1>C1*1.01) AND (O2>C2*1.01) AND (CC1) AND (OC2) AND (O11.01*H1; } else if(P == 40) { PatternName = "BigGapDown"; Pv = H<0.99*L1; } else if(P == 41) { PatternName = "HugeGapUp"; Pv = L>1.02*H1; } else if(P == 42) { PatternName = "HugeGapDown"; Pv = H<0.98*L1; } else if(P == 43) { PatternName = "DoubleGapUp"; Pv = GapUp() AND Ref(GapUp(),-1); } else if(P == 44) { PatternName = "DoubleGapDown"; Pv = GapDown() AND Ref(GapDown(),-1); } return Pv; } PatternNameList = ""; for(Cp=0; Cp<=44; Cp++) { VarSet("Pattern"+NumToStr(Cp,1.0),CandlePattern(cP)); PatternNameList = PatternNameList +PatternName+","; } BI = BarIndex(); SelectedBar = SelectedValue(BI) -BI[0]; //Selectedbar = Status("lastvisiblebar")-1; PStr=""; for(Cp=0; Cp<=44; Cp++) { Temp = VarGet("Pattern"+NumToStr(Cp,1.0)); if(temp[SelectedBar]) Pstr=Pstr+"#"+NumToStr(Cp,1.0)+" - "+StrExtract(PatternNameList,Cp)+"\n"; } FS=Param("Font Size",11,11,100,1); GfxSelectFont("Times New Roman", FS, 700, True ); GfxSetBkMode( colorWhite ); GfxSetTextColor( ParamColor("Color",colorWhite) ); Hor=Param("Horizontal Position",237,1,1200,1); Ver=Param("Vertical Position",50,1,830,1); GfxTextOut("Candle Reader= "+Pstr, Hor , Ver ); _SECTION_END();