The major issue is that nobody has fully evaluated the "liquidation value" of a stock that no longer trades. Whilst there is nothing stopping you from doing so, it's a very big task. In recent times Norgate has been researching historical corporate actions by looking up annual reports and announcement microfiche in libraries/universities... these are records the ASX just doesn't have available any more.
Originally Posted by tech/a
Typically stocks that are in an uptrend have been taken over and will close near their takeover value - which is probably good enough for a system test. Stocks in a severe downtrend sideways movement with serious downtrend that have been delisted have gone because they have failed. Any decent system with a trailing stop should have already got you out anyway. But there is the other scenario of rapid delisting perhaps with little prior notice.
It's worth evaluating your systems and see how many exits you get on the final bar of the available data and do some research on those positions. You might find you re-evaluate a large-percentage-of-capital-as-position-size.
That being said, here is some nice simple code to get you out of a position that has not been trading since X calendar days from the final bar of the chart... This was submitted to us by one of our users. The code assumes you exit the trade on the last bar of the chart if the date of the last bar's date is beyond a given threshold of calendar days.
Of course you need a data supplier with delisted data... Feedback from our users is that some systems are heavily affected, others not so much, but you don't know until you test it.
Sell = <your sell condition here>;
// Check to see if security has been delisted
NonTradedPeriod = 30;
SymbolDT = DateTimeAdd(DateTime(), NonTradedPeriod, inDaily);
Delisted = BarIndex() == (LastValue(BarIndex()) -1) AND DateTimeDiff(Now(5), SymbolDT) >= 0;
Sell = Sell or Delisted;