Skip to main content

1st hour hi low



SetChartOptions(0,chartShowArrows|chartShowDates);
_N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) ));
hv = V> 3*(MA(V,20));
colv= IIf(hv,colorCustom12,IIf(Inside(),colorGold,colorBlack));
Plot( C, "Close", colv, styleNoTitle | ParamStyle("Style") | GetPriceStyle() );

tn = TimeNum();
time1 = tn >= 091500 AND tn <= 101459;
time2 = tn >= 101500 AND tn <= 111459;
time3 = tn >= 111500 AND tn <= 121459;
time4 = tn >= 121500 AND tn <= 131459;

thigh1 = IIf(time1, HHV(H, BarsSince(time1 == False)), H);
thigh1 = IIf(time1, thigh1, Ref(thigh1, -BarsSince(time1)));
thigh2 = IIf(time2, HHV(H, BarsSince(time2 == False)), H);
thigh2 = IIf(time2, thigh2, Ref(thigh2, -BarsSince(time2)));
thigh3 = IIf(time3, HHV(H, BarsSince(time3 == False)), H);
thigh3 = IIf(time3, thigh3, Ref(thigh3, -BarsSince(time3)));
thigh4 = IIf(time4, HHV(H, BarsSince(time4 == False)), H);
thigh4 = IIf(time4, thigh4, Ref(thigh4, -BarsSince(time4)));
tlow1 = IIf(time1, LLV(L, BarsSince(time1 == False)), L);
tlow1 = IIf(time1, tlow1, Ref(tlow1, -BarsSince(time1)));
tlow2 = IIf(time2, LLV(L, BarsSince(time2 == False)), L);
tlow2 = IIf(time2, tlow2, Ref(tlow2, -BarsSince(time2)));
tlow3 = IIf(time3, LLV(L, BarsSince(time3 == False)), L);
tlow3 = IIf(time3, tlow3, Ref(tlow3, -BarsSince(time3)));
tlow4 = IIf(time4, LLV(L, BarsSince(time4 == False)), L);
tlow4 = IIf(time4, tlow4, Ref(tlow4, -BarsSince(time4)));

Today = LastValue(Day());

Plot(IIf(tn >= 091500 AND Today == Day(),thigh1,Null), "H09.15 - 10.15", ParamColor( "H09.15 - 10.15",colorLime ), styleLine|styleThick|styleDots|styleNoRescale);

Plot(IIf(tn >= 091500 AND Today == Day(),tlow1,Null), "L09.15 - 10.15", ParamColor( "L09.15 - 10.15", colorRed ), styleLine|styleThick|styleDots|styleNoRescale);

hts = -33.5;numbars = LastValue(Cum(Status("barvisible")));
fraction= IIf(StrRight(Name(),3) == "", 3.2, 3.2);
//Plot(thigh4,"",colorSkyblue,styleLine|styleDots);
thigh1I = LastValue (thigh1,1);
PlotText(" 10.15 high = " + WriteVal(thigh4,fraction), LastValue(BarIndex())-(numbars/Hts),thigh1I +0.05, colorBlue);
tlow1I = LastValue (tlow1,1);
PlotText(" 10.15 low = " + WriteVal(tlow4,fraction), LastValue(BarIndex())-(numbars/Hts),tlow1I +0.25, colorBlue);
thigh1I = LastValue (thigh1,1);
//PlotText(" 10.15 high = " + WriteVal(thigh1,fraction), LastValue(BarIndex())-(numbars/Hts),thigh1I +0.05, colorBlue);
tlow1I = LastValue (tlow4,1);
//PlotText(" 10.15 low = " + WriteVal(tlow1,fraction), LastValue(BarIndex())-(numbars/Hts),tlow1I +0.00, colorBlue);
SetChartOptions(0,chartShowArrows|chartShowDates);
GfxSetOverlayMode(0);
GfxSetTextAlign( 6 );// center alignment
GfxSetTextColor( ParamColor("Text Color", ColorHSB( 98, 119, 112 ) ));
GfxSetBkMode(0); // transparent
GfxSelectFont("Verdana", Status("pxheight")/20 );
GfxTextOut( Name(), Status("pxwidth")/2, Status("pxheight")/14 );
GfxSelectFont("Arial", Status("pxheight")/27 );
GfxTextOut(" "+C, Status("pxwidth")/2, Status("pxheight")/6.15);

Comments

Popular posts from this blog

STAN WEINSTEIN'S STRATEGY - Halan Manoj Kumar

// THIS AFL INCORPORATES MOST OF THE CONCEPTS OF STAN WEINSTEINS TRADING METHODOLOGY. // USE ONLY WEEKLY CHART. // THIS AFL DOES NOT GUARANTEE ANY POSITIVE RETURNS. // USE THIS AFL AT YOUR OWN RISK // THIS AFL WAS DEVELOPED BY HALAN MANOJ KUMAR, MSC,CAIIB,FRM,PRM,CMA,ACMA. HOWEVER IN SOME CASES INDIVIDUAL CODE SNIPPETS ARE FROM DIFFERENT SOURCES AND I THANK THOSE DEVELOPERS. // ANY CONCEPTUAL QUERIES OR COMMENTS CAN BE MAILED TO scorpiomanoj73@gmail.com _SECTION_BEGIN("CHART"); SetChartOptions(0,chartShowArrows|chartShowDates); _N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%)", O, H, L, C, SelectedValue( ROC( C, 1 ) ) )); Plot( C, "Close", ParamColor("Color", colorDefault ), styleNoTitle | ParamStyle("Style") | GetPriceStyle() ); _SECTION_END(); //RELATIVE STRENGTH // IF YOUR NIFTY TRADING SYMBOL IS DIFFERENT, PLEASE USE THAT INSTEAD OF ONE MENTIONED HERE. rsmaPeriod...

10K AFL FREE INTRADAY TRADING.afl

_SECTION_BEGIN("Price1"); SetChartOptions(0,chartShowArrows|chartShowDates); Plot( C, "Close", ParamColor("Color", colorRed ), styleNoTitle | ParamStyle("Style") | GetPriceStyle() ); _SECTION_END(); //_SECTION_BEGIN("Pivot")     YH = TimeFrameGetPrice("H", inDaily, -1);        // yesterdays high     YL = TimeFrameGetPrice("L", inDaily, -1);        //                low     YC = TimeFrameGetPrice("C", inDaily, -1);        //                close     YO = TimeFrameGetPrice("O", inDaily);            // current day open     //Normal Pivot     PP = (YH + YL + YC) / 3;     R1 = (2 * PP) - YL;     R2 = PP + (YH - YL); ...

TDI

TDI - Indicator  Many things together in one simple, small indicator .... Buy-Sell Signals , Avoid False Signals, check Volatility.... For short, medium trading and long term investing ... // // The Code /* 1) Enter long when the green line is above the red line AND enter Short when the red line is the above green line. 2) for Short-term trading, enter long when the green is above both the red AND the brown line; 3) Enter Short when the red one is above both the green AND the brown ones. 4) for medium-term trading, go long under the same conditions as for the Short-term trading but only when all lines are below 50; to go Short — the same but above 50. 5) Mind the blue volatility band as it points to the long-term trend strength AND volatility when wide. Steep green line changes also Signal Short-term market volatility. */ SetChartBkColor (ParamColor("Ou ter panel color ",colorLightYel low)); // color of outer border SetChartBkGradi entFill( ParamColor("Inn er pan...