How to Highlight a Bar 49 Bars Ago

Marking a Bar 49 Days Back

17:29 FuturesTrader: Is there a DYO way to highlite the 49'th candlestick fon a daily chart? Just that one candle.

17:29 Ensign Howard: What is 49th relative to?

17:29 FuturesTrader: 49 days ago. Offset -48

17:30 Ensign Howard: ok, so it is the bar today -48. Yes, let me post picture of the solution.... 1 moment.

17:30 FuturesTrader: Yes

17:46 Ensign Howard: Line A is storing in GV[1] the index for the bar which is 48 back from the last bar on the chart.

17:46 Ensign Howard: The last bar on the chart will be at bar index Bar Count. So if there are 300 bars on the chart, then GV[1] will have a value of 300-48 = 252

17:47 Ensign Howard: Then Line B tests each bar as it processes across the chart to see if that bar's index is 252, and when bar at position 252 is found its zone is colored.

17:48 FuturesTrader: I never would have figured that out. Thanks so much!!! This is related to Chick Goslin's book -- so there may be other interest.

17:51 Ensign Howard: Now there are also DYO statements to harvest the open, high, low, last values for the bar at index #. So if you needed the prices from this marked bar, they can be read and used in your calculations or tests.

17:53 FuturesTrader: Right -- this particular intention is a visual aid for determining whether the 49-day SMA slope is going to turn more positive or negative based on the oldest days about to drop off being above or below the current price.

17:55 Ensign Howard: aahh.... good clue. You could automate that visual by the momentum of 49. All you need compare is the close value of 49 back versus now to know if the SMA will rise or fall as oldest drops off. So the momentum of 49 can be the visual test to color the current bar zone green or red with the meaning that green the oldest is lower and so SMA should rise and red means oldest is higher, and when it drops off the SMA should fall

18:02 Ensign Howard: So the chart is now color coded, and I am not even looking at the SMA. But SMA would be rising in the green areas, and falling in the red areas and our blue marker bar is above current bar, so as it drops off, current SMA would have to fall, so the current zone is correctly colored red.

18:03 FuturesTrader: That's great! Cool concept to facilitate projecting the SMA slope is the days ahead.