Great thanks jcl,

How do I exclude priceClose[0] and get the Maxval of priceClose[1] to [8].

Sorry, I'm used to metatrader, where you specify the bar you want to lookback from and the number of bars to lookback.