Announcement

Collapse
No announcement yet.

Yearly OHLC

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Yearly OHLC

    Hi,
    I've used the formula in this thread to display Yearly OHLC candlestick overlays on a chart. I can only get it to display the previous Years data, so 2010 is displaying 2009 data. I've tried changing the following code, but I can't get it to work:

    if(getBarState()==BARSTATE_NEWBAR&&getYear()!=getY ear(-1)) { // Yearly

    ...to...

    if(getBarState()==BARSTATE_NEWBAR&&getYear()!=getY ear(0)) { // Yearly

    Also, can Yearly data be utilised to display OHLC data for 5 or 10 Year Time Frames?

    Thanks,
    Paul
Working...
X