HighVal(0) is NA for all stocks

close(0) is fine though. As is HighVal(1).

See this public screen.

Aggregate(“HighVal(1)/Lowval(1)”, #All, #Avg) is also NA.

HighVal can’t take 0 as a period parameter. What would that mean? The highest closing price in the last 0 bars? Perhaps you want Hi(0)?

As for HighVal(1)/LowVal(1) that would always be 1, since the highest closing price of the last 1 bars would always be the same as the lowest. And the Aggregate doesn’t return NA, it returns 1, as it should.

I meant Hi(0) and Low(0).

Thank you.