What does Exit Downsells and Thank-You Add-Ons conclude, in numbers, about “The Exit-Risk Function: What Cursor Tracks Predict, and What Is Left on a Touch Screen”?

Answer: The cut-off decides who sees the pop-up. With a cut-off of 0.3, the share of leavers who are caught, the recall, is 0.517; the share of pop-ups that land on people who were really leaving, the precision, is 0.495; and the share of stayers who are interrupted by mistake, the false-pop rate, is 0.114. Raise the cut-off to 0.5 and precision climbs to 0.667 while recall falls to 0.260 and the false-pop rate to 0.028. Raise it again to 0.7 and precision reaches 0.792, but recall is down to 0.107 and the false-pop rate to 0.006.

Scope of the numbers: Cursor tracks do carry information about intent, but a model returns probabilities: on synthetic desktop data the AUC is 0.809, falling to 0.618 for touch sessions that lose the cursor signals. Parameters are illustrative, all calculations are generated by the book's programs, and all prices are unitless illustrative units.

中文版

Data table

The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 0.006, 0.028, 0.107, 0.114, 0.260, 0.3

sessions 4,000 test exit base rate 0.177
fitted beta-2.73 +0.94 +0.63 +0.06 +0.72
true beta-2.60 +0.90 +0.50 +0.06 +0.50
test AUC 0.809
cut pops precision recall false-pop rate
0.3370 0.495 0.517 0.114
0.5138 0.667 0.260 0.028
0.748 0.792 0.107 0.006
Show the full program
# Chapter 1. p11: an exit-risk logistic model on synthetic cursor tracks.
# Model: each desktop session snapshot has four signals: cursor speed
# toward the top bar (v_up), upward acceleration (a_up), idle seconds
# (idle) and scroll stall (stall, 1 if no scroll for 5 s). The true
# chance of leaving within 2 s is logistic in these signals. We fit
# the model on half the data by Newton steps (IRLS) and score the other
# half: AUC, then precision, recall and false-pop rate at 3 cut-offs.
# All coefficients are illustrative; replace them with your own logs.
import math
import random

rng = random.Random(39811)
TRUE = [-2.6, 0.9, 0.5, 0.06, 0.5]


def sigmoid(z):
    if z < -30.0:
        return 0.0
    if z > 30.0:
        return 1.0
    return 1.0 / (1.0 + math.exp(-z))


def make(n):
    rows = []
    for _ in range(n):
        v_up = rng.gauss(0.0, 1.0)
        a_up = 0.5 * v_up + rng.gauss(0.0, 0.9)
        idle = rng.expovariate(1.0 / 6.0)
        stall = 1.0 if rng.random() < 0.35 else 0.0
        x = [1.0, v_up, a_up, idle, stall]
        z = math.fsum(b * f for b, f in zip(TRUE, x))
        y = 1 if rng.random() < sigmoid(z) else 0
        rows.append((x, y))
    return rows


def solve(a, b):
    n = len(b)
    m = [row[:] + [b[i]] for i, row in enumerate(a)]
    for c in range(n):
        piv = max(range(c, n), key=lambda r: abs(m[r][c]))
        m[c], m[piv] = m[piv], m[c]
        for r in range(n):
            if r != c:
                f = m[r][c] / m[c][c]
                m[r] = [u - f * w for u, w in zip(m[r], m[c])]
    return [m[i][n] / m[i][i] for i in range(n)]


def irls(rows, k, steps=12):
    beta = [0.0] * k
    for _ in range(steps):
        grad = [0.0] * k
        hess = [[0.0] * k for _ in range(k)]
        gterms = [[] for _ in range(k)]
        hterms = [[[] for _ in range(k)] for _ in range(k)]
        for x, y in rows:
            p = sigmoid(math.fsum(b * f for b, f in zip(beta, x)))
            w = p * (1.0 - p)
            for i in range(k):
                gterms[i].append((y - p) * x[i])
                for j in range(k):
                    hterms[i][j].append(w * x[i] * x[j])
        for i in range(k):
            grad[i] = math.fsum(gterms[i])
            for j in range(k):
                hess[i][j] = math.fsum(hterms[i][j])
        step = solve(hess, grad)
        beta = [b + s for b, s in zip(beta, step)]
    return beta


def auc(scores, labels):
    pairs = sorted(zip(scores, labels))
    rank_sum, n1 = 0, 0
    for r, (_, y) in enumerate(pairs, 1):
        if y == 1:
            rank_sum += r
            n1 += 1
    n0 = len(pairs) - n1
    return (rank_sum - n1 * (n1 + 1) / 2.0) / (n1 * n0)


data = make(4000)
train, test = data[:2000], data[2000:]
beta = irls(train, 5)
scores = [sigmoid(math.fsum(b * f for b, f in zip(beta, x)))
          for x, _ in test]
labels = [y for _, y in test]
base = math.fsum(labels) / len(labels)
print("sessions {:,}  test exit base rate {:.3f}".format(len(data), base))
print("fitted beta: " + " ".join("{:+.2f}".format(b) for b in beta))
print("true   beta: " + " ".join("{:+.2f}".format(b) for b in TRUE))
print("test AUC {:.3f}".format(auc(scores, labels)))
print("cut   pops  precision  recall  false-pop rate")
for cut in (0.3, 0.5, 0.7):
    tp = fp = fn = tn = 0
    for s, y in zip(scores, labels):
        if s >= cut:
            tp, fp = tp + y, fp + (1 - y)
        else:
            fn, tn = fn + y, tn + (1 - y)
    print("{:.1f}  {:5d}  {:9.3f}  {:6.3f}  {:14.3f}".format(
        cut, tp + fp, tp / max(1, tp + fp), tp / max(1, tp + fn),
        fp / max(1, fp + tn)))

Single source and citation

Fan, Y. (2026). Exit-Trajectory Micro-Downsells, Zero-Friction Lead Magnet Capture and Thank-You-Page Ten-Second Monetisation (Version 1.0.0), Chapter 1: The Exit-Risk Function: What Cursor Tracks Predict, and What Is Left on a Touch Screen. 5D Library. DOI pending

DOI pending · monograph page goes live after publication · 5DL-B-398 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026398,
  author    = {Fan, Yafu},
  title     = {Exit-Trajectory Micro-Downsells, Zero-Friction Lead Magnet Capture and Thank-You-Page Ten-Second Monetisation},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  note      = {DOI pending}
}

Other chapter answers in this book