Skip to main content
Version: 3.0

Normal CDF Scoring

Uses the log-normal distribution to quantify how "common" a rate is relative to the observed distribution for that code. The CDF score becomes the decimal portion of the accuracy score — used as a tiebreaker between rates with the same integer tier.

Walk-Through: CDF Computation

Setup: Code 99213, pre-computed stats: median=4.8 (log-space), stddev=0.6
Rate A: $150 → ln($150)=5.01 → epsilon=0.05×4.8=0.24
CDF window: normal_cdf(4.8, 0.6, 5.01-0.24) - normal_cdf(4.8, 0.6, 5.01+0.24)
Result: CDF = 0.78 (78% of observed rates fall in a similar range → very common)
Rate B: $500 → ln($500)=6.21 → CDF = 0.05 (only 5% of rates are this high → unusual)
Rate A gets score 6.78, Rate B gets score 6.05 Both are "raw, not outlier" (integer tier 6), but A is preferred as tiebreaker
Normal CDF Scoring
-- Normal CDF Scoring
-- Quantifies how common a rate is using log-normal distribution
-- Pre-computed outlier bounds provide median and stddev per code

-- Epsilon = 5% of distribution median (narrow confidence window)
-- CDF returns 0-1: higher = more common rate value

CASE
-- Drugs skip CDF (use ASP-based bounds instead)
WHEN is_drug_code = true OR ob.stddev IS NULL OR ob.stddev = 0
THEN 0
-- Cap extreme values at 0.999
WHEN ABS(
normal_cdf(ob.median, ob.stddev, LN(rate) - 0.05 * ob.median)
- normal_cdf(ob.median, ob.stddev, LN(rate) + 0.05 * ob.median)
) = 1
THEN 0.999
ELSE ABS(
normal_cdf(ob.median, ob.stddev, LN(rate) - 0.05 * ob.median)
- normal_cdf(ob.median, ob.stddev, LN(rate) + 0.05 * ob.median)
)
END AS rate_cdf

-- CDF is added as decimal portion of accuracy score:
-- Score 6 + CDF 0.78 = 6.78 (beats 6.45, same tier but more common rate)
-- Score 7 uses rate/1e8 instead (prefer higher validated rates)
Drug exception

Drug codes (is_drug_code=true) get CDF=0, not distribution-based scoring. Drug rates are evaluated purely against ASP bounds because drug pricing distributions are highly bimodal (brand vs generic).