Try this
ThisIsLastBar = BarIndex() == LastValue( BarIndex() );
Filter=ThisIsLastBar;
AddColumn(ThisIsLastBar,"lastbar");
Cheers
Khaleel
--- In amibroker@xxxxxxxxxps.com,
"David" <david.smith5@...> wrote:
>
> Hi, does anyone
know a way to determine if the last bar has
occurred
> in a delisted
stock. I have a database of delisted securities I
would
> like to
test for survivorship bias and would like to force a trade
to
>
close at the closing price if the last bar occurs, otherwise the
trade
> stays open.
>
> Regards,
David
>