Hi

I do want to compare the current value of a MovingAverage to a the highest value within the last 9 bars, excluding the current one, as a condition in an IF-statement.

something like if MA > Highest(MA,9)[1] then do this and that

I've found HH() but seems only to be useable for priceData and not an indicator.
MaxVal() expect to use series. So I did try:
Code
 if(MA>MaxVal(MA[1],9)

but that throws an error (pointer expected).

I probably could find out what I need with a loop, but that seems to be an overkill and somehow inefficient for my little task.