Futurestrader71 talks about the 'mid' alot. I have been trying to implement this level on my TOS charts but cant figure it out. I tried to create a simple moving average with a look back of 78 periods (5 min chart) with a calculation of (H+L)/2. Doesnt seem right.
FT71 did tweet and say "it charts the average of the high & low throughout whatever session I have selected. Generally pit only" - This is in relation to E-Mini S&P500 futures.
Anyone know how to calculate this in a script or define it in a study in TOS. Thanks in advance.
Last edited by smegey; July 26th, 2016 at 11:08 PM.
def CapturePeriodHasBegun = secondsFromTime(CapturePeriodStart) > 0;
def FirstBarOfCapturePeriod = !CapturePeriodHasBegun and CapturePeriodHasBegun;
def PriorPeriod = secondsFromTime(CapturePeriodStart) > 0 or secondsFromTime(CapturePeriodEnd) < 0;
def PlotPeriod = secondsFromTime(StartPlotTime) > 0 && secondsTillTime(EndPlotTime) > 0;
rec PriorPeriodHigh = if IsNaN(PriorPeriodHigh) or PriorPeriodHigh < 2 then high
else if FirstBarOfCapturePeriod then high else if PriorPeriod && high > PriorPeriodHigh then
high else PriorPeriodHigh;
rec PriorPeriodLow = if IsNaN(PriorPeriodLow) or PriorPeriodLow < 2 then low else
if FirstBarOfCapturePeriod then low else if PriorPeriod && low < PriorPeriodLow then low else
def TheHigh = if PlotPeriod && PriorPeriodHigh > 2 then PriorPeriodHigh else
def TheLow = if PlotPeriod && PriorPeriodLow > 2 then PriorPeriodLow else
Devildriver6 - Have you compared your script to FT71 charts? On his traderbites it seems very close but not the same. Just wondering if its me or indeed its a tad different. Perhaps its user error on my part....