Write a detection rule that alerts when a market data feed goes stale for one symbol, given that some symbols print 40 times a second and others twice an hour. State the statistic, the threshold, and the false alarm rate you would accept.

Write a detection rule that alerts when a market data feed goes stale for one symbol, given that some symbols print 40 times a second and others twice an hour. State the statistic, the threshold, and the false alarm rate you would accept.

Approach: Make the rule scale free by measuring the current gap against that symbol's own arrival history at the same time of day, then choose the threshold from the tail of that distribution.

Alert when the time since a symbol's last print exceeds 3 times that symbol's own trailing 99th percentile inter arrival gap for the same minute of the session, with a floor of 5 seconds. A single global timeout cannot work, because 2 seconds of silence is a dead feed for a symbol printing 40 times a second and an ordinary morning for one printing twice an hour. Estimating a per symbol baseline from a trailing window of the same session minute handles both, and also handles the open and the close, where gaps for one symbol change by an order of magnitude within the day. Use a quantile threshold rather than a mean plus k standard deviations, because inter arrival gaps are heavy tailed and the standard deviation is dominated by the very tail the rule is meant to detect. Set the multiple from the false alarm rate you will accept: at the 99th percentile with a multiple of 3, a healthy symbol should fire well under once a day, which is the level at which an alert is still read. Add two guards. Suppress during a halt or outside the session, since a halt is indistinguishable from a dead feed by arrival times alone. And alert on the count of stale symbols per feed, because a real failure hits hundreds at once and a hundred separate pages are worse than one.

Follow-up: How would you separate a dead feed handler from a genuinely quiet market when both produce zero prints?

Key concepts: inter arrival gap, per symbol baseline, quantile threshold, false alarm rate.