Yes. its returning close of the first 3 min candle of the new day.
The below is the complete code, Previous Day High, Previous Day Low giving exact value only previous Day Close
_SECTION_BEGIN("Price");
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 ) ) ));
bartime = Status( "lastbartimeleft" );
mts = int(bartime / 60);
sds = int(frac(bartime / 60) * 60);
if ( bartime > 0 ) {
txt = StrFormat( "%g:%02.0f", mts, sds);
x = Status("pxchartright");
} else {
txt = "0.00";
x = Status("pxchartright") - GfxGetTextWidth(txt);
}
Plot( C, "Close", ParamColor("Color", colorDefault ), styleNoTitle | ParamStyle("Style") | GetPriceStyle());
GfxSetCoordsMode(2);
GfxSetBkColor(ColorBlue);
GfxSetTextColor(ColorWhite);
GfxSelectFont("Tahoma", 14, 800 );
GfxTextOut(txt, x, LastValue(C));
printf("Bismillaahi Avvalahu Wa Akhirahu\n");
//Common variables
Starttime = TimeNum() > 093000 ;
endtime = TimeNum() < 150000 ;
EODsquareoff = TimeNum() == 150000 ;
newday = Day() != Ref(Day(),-1) ;
orbperiod15=15;
orbperiod30=30;
orbh15 = ValueWhen(newday,TimeFrameGetPrice("H",in1Minute*orbperiod15,0)) ;
orbl15 = ValueWhen(newday,TimeFrameGetPrice("L",in1Minute*orbperiod15,0)) ;
orbl5 = ValueWhen(newday,TimeFrameGetPrice("L",in1Minute*5,0)) ;
orbh5 = ValueWhen(newday,TimeFrameGetPrice("H",in1Minute*5,0)) ;
orbh30 = ValueWhen(newday,TimeFrameGetPrice("H",in1Minute*orbperiod30,0)) ;
orbl30 = ValueWhen(newday,TimeFrameGetPrice("L",in1Minute*orbperiod30,0)) ;
//orbl15 = ValueWhen(newday,TimeFrameGetPrice("L",in1Minute*15,0)) ;
pdh = ValueWhen(newday,TimeFrameGetPrice("H",inDaily,-1)) ;
pdl = ValueWhen(newday,TimeFrameGetPrice("L",inDaily,-1)) ;
pdc = ValueWhen(newday,TimeFrameGetPrice("C",inDaily,-1)) ;
printf(" pdc %g\n",pdc);
orbh15 = IIf(TimeNum()<starttime,Null,orbh15); //redefining the ORBH value
orbl15 = IIf(TimeNum()<starttime,Null,orbl15); //redefining the ORBL value
orbl5= IIf(TimeNum()<starttime,Null,orbl5); //redefining the ORBL value
orbh30 = IIf(TimeNum()<starttime,Null,orbh30); //redefining the ORBH value
orbl30 = IIf(TimeNum()<starttime,Null,orbl30); //redefining the ORBL value
pdh = IIf(TimeNum()<starttime,Null,pdh); //redefining the PDH
pdl = IIf(TimeNum()<starttime,Null,pdl); //redefining the PDL
pdc = IIf(TimeNum()<starttime,Null,pdc); //redefining the PDC
LVBI = LastVisibleValue(BarIndex());
Plot(orbh15,"15 Min HIGH",colorRed,styleThick);
Plot(orbl15,"ORBL15",colorGreen,styleLine);
Plot(orbl5,"ORBL5",colorBlue,styleDashed);
Plot(orbh5,"ORBH5",colorBlue,styleDashed);
Plot(orbh30,"ORBH30",colorRed,styleThick);
Plot(orbl30,"ORBL30",colorGreen,styleThick);
Plot(pdc,"PDC",colorBlack,styleThick);
//Plot(pdh,"PDH",colorRED,styleThick);
//Plot(pdl,"PDL",colorGreen,styleThick);
//Plot(pdh,"PDH",colorOrange,styleDashed);
//Plot(pdl,"PDL",colorBrown,styleDashed);
//Plotting Text on HIGH LOWS
PlotTextSetFont(" 15 Min HIGH ", "Tahoma", 10, LVBI+5 , SelectedValue(orbh15), colorWhite, colorRed, -10);
PlotTextSetFont(" 15 Min LOW ", "Tahoma", 10, LVBI+5 , SelectedValue(orbl15), colorWhite, colorGreen, 10);
PlotTextSetFont(" 5 Min LOW ", "Tahoma", 10, LVBI+5 , SelectedValue(orbl5), colorWhite, colorGreen, 10);
PlotTextSetFont(" 5 Min HIGH ", "Tahoma", 10, LVBI+5 , SelectedValue(orbh5), colorWhite, colorRed, 10);
PlotTextSetFont(" 30 Min HIGH ", "Tahoma", 10, LVBI+5 , SelectedValue(orbh30), colorWhite, colorRed, 5);
PlotTextSetFont(" 30 Min LOW ", "Tahoma", 10, LVBI+5 , SelectedValue(orbl30), colorWhite, colorGreen, -10);
PlotTextSetFont(" Prev Day CLOSE ", "Tahoma", 10, LVBI+5 , SelectedValue(pdc), colorWhite, colorBlue, 0);
//PlotTextSetFont(" Prev Day HIGH ", "Tahoma", 10, LVBI+5 , SelectedValue(pdh), colorWhite, colorBlue, 0);
//PlotTextSetFont(" Prev Day LOW ", "Tahoma", 10, LVBI+5 , SelectedValue(pdl), colorWhite, colorBlue, 0);
Plot(EMA(C,21),"EMA-21",colorBlue,styleLine|styleThick);
Plot(EMA(C,200),"EMA-200",colorBrown,styleLine|styleThick);
_SECTION_END();
Please find attached screen shots for your reference