Hi there,

I'm looking for TOS similar function in Amibroker. The following is the function

```
GetValue(high, InsideBars[1] + 1, 0)
```

It is use in this formula

```
input MinCompressionLength = 4;
input BubbleAbove = yes;
input TurnOffPlot = no;
def InsideBars =
if InsideBars[1] == 0 then
if MAX(Open,Close) <= high[1] and Min(Open,Close) >= low[1] then 1
else 0
else
if MAX(Open,Close) <= GetValue(high, InsideBars[1] + 1, 0) and
Min(Open,Close) >= GetValue(low, InsideBars[1] + 1, 0)
then InsideBars[1] + 1
else 0;
AddChartBubble(!TurnOffPlot and InsideBars >= MinCompressionLength and !InsideBars[-1], high,
InsideBars, Color.GRAY, BubbleAbove);
```

This is what it does

This formula look for inside bar and number them starting from the Anchor bar. I'm actually looking how to define this Anchor bar in amibroker. I always get looped when dealing with formula that go in a loop, as in this case so appreciate all help to get me out of this loop

Thanks to all