Computes the cumulative distribution function \(P(K_J \leq k \mid a, b)\) for \(k = 0, 1, \ldots, J\).
Value
Numeric vector of length \(J+1\) containing \(P(K_J \leq k \mid a, b)\) for \(k = 0, 1, \ldots, J\).
Details
The CDF satisfies:
\(F(0) = 0\) (since \(P(K_J = 0) = 0\))
\(F(J) = 1\)
\(F(k)\) is non-decreasing in \(k\)
Examples
logS <- compute_log_stirling(50)
cdf <- cdf_K_marginal(50, 1.5, 0.5, logS)
# Verify CDF ends at 1
cdf[51]
#> [1] 1
# P(K <= 10)
cdf[11]
#> [1] 0.7009381