关于「实践与预注册检验」,《亚知觉色胺动力学与可塑性窗口》给出的定量结论是什么?

结论:第八章给出四步核查表与一项预注册双盲试验:最小关注效应 0.30 个标准差,每臂随机 282 例,共 564 例,设盲完整性写入判定规则。书中以标注框区分已发表的证据、可运行的 Python 计算(16 段程序)、原典与作者的模型和假说;除注明的文献数据外,书中数据都是合成的。

数据口径:本书是教学与研究用的生物数学与方法学讨论,不是医疗建议,也不是任何物质的使用指南。 本书讨论的物质在多数司法辖区受管制;书中不给出任何剂量、质量、产品、来源、途径、合成或疗程:全书的剂量一律以相对于一个未指定参考值的无量纲比值表示,这是第 8 本确立的写法。

English version

对照数据表

下表数字由本章 Python 程序原样打印,可重新运行复现。 程序只用 Python 标准库与结论吻合的打印值: 0.30, 282, 564

outcome = mean of 2 occasions; single-occasion reliability 0.80 -> 0.889
normal theory: n = 184.184 -> 185 per arm (attenuated d = 0.283)
simulation with integer scores and a ceiling at 70:
   n = 185/arm: power 0.881 (s.e. 0.008); active arm at ceiling 0.7%
   n = 195/arm: power 0.892 (s.e. 0.008); active arm at ceiling 0.7%
   n = 210/arm: power 0.913 (s.e. 0.007); active arm at ceiling 0.7%
   n = 225/arm: power 0.928 (s.e. 0.007); active arm at ceiling 0.7%
   smallest n with power - 2 s.e. >= 0.90: 225
   one-sided error rate with no effect: 0.025 (nominal 0.025)
Drop-out in a six-week daily-dosing protocol is higher than in a
questionnaire-only study; the plan allows 20 %:
   225 analysable per arm; 20 % loss -> 282 randomised per arm, 564 in all
sensitivity, analysable per arm (normal theory, reliability 0.89):
   SESOI \ rho        0.35    0.55    0.75
   0.20 SD             520     414     260
   0.30 SD             232     185     116
   0.40 SD             131     105      66
The trial is powered for the PRIMARY comparison only. Programme p14
showed that the belief-stratified contrast, which is the analysis that
separates pharmacology from expectancy, would need several times this
sample if the blind does not hold; it is therefore a pre-specified key
secondary reported with its interval and is not powered. The blind-
integrity check at 225 per arm can detect a correct-guess rate of about
   0.607, which is the resolution the trial has on its own blind.
查看完整验算程序
# Chapter 8. Sample size for the pre-registered trial. Single primary
# comparison: the active condition against a matched placebo, double blind.
# Single primary outcome: the pre-specified wellbeing/affect score at week 6
# by ANCOVA (baseline, site). Planning
# assumptions: SESOI 0.30 SD, baseline-outcome correlation 0.55,
# single-occasion reliability 0.80, outcome = mean of 2 occasions, two-sided
# 0.05, 90 % power. Normal theory first, then a simulation with integer
# scoring, a ceiling, and the drop-out pattern that long daily-dosing
# protocols actually produce.
import math
import random
from statistics import NormalDist

Z = NormalDist().inv_cdf
D, RHO, REL1, K_OCC = 0.30, 0.55, 0.80, 2
ITEMS, ITEM_MAX = 14, 5           # 14 items scored 0-5: range 0-70
CEILING = ITEMS * ITEM_MAX
TRUE_MEAN, TRUE_SD = 42.0, 9.5

def reliability(k):
    return k * REL1 / (1 + (k - 1) * REL1)

def n_formula(d=D, rho_xx=1.0, rho=RHO, power=0.90, alpha=0.05):
    d_obs = d * math.sqrt(rho_xx)
    za, zb = Z(1 - alpha / 2), Z(power)
    return 2 * (za + zb) ** 2 * (1 - rho ** 2) / d_obs ** 2 + za ** 2 / 4

def invert3(S):
    a, b, c = S[0]
    d, e, f = S[1]
    g, h, i = S[2]
    det = a * (e * i - f * h) - b * (d * i - f * g) + c * (d * h - e * g)
    return [
        [(e * i - f * h) / det, (c * h - b * i) / det, (b * f - c * e) / det],
        [(f * g - d * i) / det, (a * i - c * g) / det, (c * d - a * f) / det],
        [(d * h - e * g) / det, (b * g - a * h) / det, (a * e - b * d) / det],
    ]

def one_trial(rng, n, delta_sd):
    rows = []
    delta = delta_sd * TRUE_SD
    err_sd = TRUE_SD * math.sqrt(1 - RHO ** 2)
    meas_sd = TRUE_SD * math.sqrt((1 - REL1) / REL1 / K_OCC)
    for arm in (1, 0):
        for _ in range(n):
            lat_b = rng.gauss(TRUE_MEAN, TRUE_SD)
            b = min(CEILING, max(0, round(lat_b + rng.gauss(0, meas_sd))))
            lat_y = (TRUE_MEAN + RHO * (lat_b - TRUE_MEAN) + delta * arm
                     + rng.gauss(0, err_sd))
            y = min(CEILING, max(0, round(lat_y + rng.gauss(0, meas_sd))))
            rows.append((arm, b, y))
    n2 = len(rows)
    mb = math.fsum(r[1] for r in rows) / n2
    X = [(1.0, float(r[0]), r[1] - mb) for r in rows]
    Y = [float(r[2]) for r in rows]
    S = [
        [math.fsum(x[i] * x[j] for x in X) for j in range(3)]
        for i in range(3)
    ]
    v = [math.fsum(x[i] * y for x, y in zip(X, Y)) for i in range(3)]
    inv = invert3(S)
    beta = [math.fsum(inv[i][j] * v[j] for j in range(3)) for i in range(3)]
    res = [
        y - math.fsum(bb * xx for bb, xx in zip(beta, x))
        for x, y in zip(X, Y)
    ]
    s2 = math.fsum(r * r for r in res) / (n2 - 3)
    df = n2 - 3
    z = Z(0.975)
    tcrit = z + (z ** 3 + z) / (4 * df)
    at_ceiling = sum(1 for r in rows if r[0] == 1 and r[2] == CEILING) / n
    return beta[1] / math.sqrt(s2 * inv[1][1]) > tcrit, at_ceiling

if __name__ == "__main__":
    rel = reliability(K_OCC)
    print(
        "outcome = mean of {} occasions; single-occasion reliability {:.2f}"
        " -> {:.3f}".format(K_OCC, REL1, rel)
    )
    n0 = n_formula(rho_xx=rel)
    print("normal theory: n = {:.3f} -> {} per arm (attenuated d = {:.3f})"
          .format(n0, math.ceil(n0), D * math.sqrt(rel)))

    rng = random.Random(5215)
    print(
        "\nsimulation with integer scores and a ceiling at {}:".format(
            CEILING
        )
    )
    chosen = None
    for n in sorted({math.ceil(n0), 195, 210, 225}):
        res = [one_trial(rng, n, D) for _ in range(1500)]
        pw = sum(r[0] for r in res) / len(res)
        se = math.sqrt(pw * (1 - pw) / len(res))
        ce = math.fsum(r[1] for r in res) / len(res)
        print(
            "   n = {:3d}/arm: power {:.3f} (s.e. {:.3f}); active arm at"
            " ceiling {:.1%}".format(n, pw, se, ce)
        )
        if chosen is None and pw - 2 * se >= 0.90:
            chosen = n
    if chosen is None:
        chosen = 210
    t1 = sum(one_trial(rng, chosen, 0.0)[0] for _ in range(1500)) / 1500
    print("   smallest n with power - 2 s.e. >= 0.90: {}".format(chosen))
    print(
        "   one-sided error rate with no effect: {:.3f} (nominal 0.025)"
        .format(t1)
    )

    print(
        "\nDrop-out in a six-week daily-dosing protocol is higher than in a"
    )
    print("questionnaire-only study; the plan allows 20 %:")
    plan = math.ceil(chosen / 0.80)
    print(
        "   {} analysable per arm; 20 % loss -> {} randomised per arm, {}"
        " in all".format(chosen, plan, 2 * plan)
    )

    print(
        "\nsensitivity, analysable per arm (normal theory, reliability"
        " {:.2f}):".format(rel)
    )
    print("   SESOI \\ rho        0.35    0.55    0.75")
    for d in (0.20, 0.30, 0.40):
        print("   {:4.2f} SD        ".format(d) + "".join(
            "{:8d}".format(math.ceil(n_formula(d=d, rho_xx=rel, rho=r)))
            for r in (0.35, 0.55, 0.75)))

    print(
        "\nThe trial is powered for the PRIMARY comparison only."
        " Programme p14"
    )
    print(
        "showed that the belief-stratified contrast, which is the analysis"
        " that"
    )
    print(
        "separates pharmacology from expectancy, would need several times"
        " this"
    )
    print(
        "sample if the blind does not hold; it is therefore a"
        " pre-specified key"
    )
    print(
        "secondary reported with its interval and is not powered. The blind-"
    )
    print(
        "integrity check at {} per arm can detect a correct-guess rate of"
        " about".format(chosen)
    )
    lo, hi = 0.5001, 0.95
    for _ in range(60):
        mid = 0.5 * (lo + hi)
        k = (
            (Z(0.975) * 0.5 + Z(0.90) * math.sqrt(mid * (1 - mid)))
            / (mid - 0.5)
        ) ** 2
        if k > chosen:
            lo = mid
        else:
            hi = mid
    print("   {:.3f}, which is the resolution the trial has on its own blind."
          .format(hi))

唯一数据源与引用

范雅福(Fan, Y.). (2026). 《亚知觉色胺药代动力学、5-HT2A 受体脱敏与神经可塑性窗口的生物数学模型》第 8 章「实践与预注册检验」(版本 1.0.0). 5D Library. https://doi.org/10.5281/zenodo.24019347

DOI: 10.5281/zenodo.24019347 · 阅读本章所在专著 · 5DL-B-054 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026054,
  author    = {Fan, Yafu},
  title     = {Biomathematical Models of Sub-Perceptual Tryptamine Pharmacokinetics, 5-HT2A Receptor Desensitisation and Neuroplastic Window Dynamics},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  doi       = {10.5281/zenodo.24019347},
  url       = {https://doi.org/10.5281/zenodo.24019347}
}

本书其他章节结论