Member Junction
    Preparing search index...
    • Computes days_since_last_activity as of the cutoff: the whole-day gap between the cutoff date and the most recent surviving event. Returns null when there is no qualifying activity (the caller decides how to encode "no activity" — typically imputed downstream by the sidecar, §6.2).

      Computing recency relative to the as-of date (not "now") is what keeps train-time ("as-of-then") and score-time ("as-of-now") consistent.

      Parameters

      • rows: DatedRow[]

        candidate dated rows (will be filtered to the cutoff internally)

      • asOfDate: Date

        the resolved cutoff; when null, recency is measured from "now"

      Returns number