2026-08-28·by Sijie Wang#idea#math

threshold

Threshold — VC = 1

Parent: examples Prereq: learning-theoryH, h, shattering; .

Class H={ht:tR}H = \{\, h_t : t \in \mathbb{R} \,\}, one parameter:

ht(x)={+xtx<th_t(x) = \begin{cases} + & x \ge t \\ - & x < t \end{cases}

Let's count. (Recall ht(p)=+h_t(p) = {+} iff tpt \le p.)

Shatter 1 point p? label +: take any t ≤ p; label : take any t > p. Both realizable → shatters 1 → VC ≥ 1.

Shatter 2 points p₁ < p₂? write the labeling as (h(p₁), h(p₂)) and solve for t in each of the 2²=4 cases:

labelingcondition on trealizable?
(−,−)t > p₂
(−,+)p₁ < t ≤ p₂
(+,+)t ≤ p₁
(+,−)t ≤ p₁ and t > p₂, i.e. p₂ < t ≤ p₁empty since p₁ < p₂

(+,−) has no solution → no 2 points can be shattered → VC < 2. So VC = 1.

Breaks on any non-monotone pattern, e.g. − + − ("positive only in the middle"): that rule is not in H at all → underfit. Climb one step → interval.

about this entry

One of sijie's wiki entries. The AI on this site is grounded in the same corpus and answers in sijie's voice, with citations back to entries like this one — answering costs sijie money, so it waits behind a code: enter an access code →