This site is version 0.0.1. Most of the code on this site is drafted by an agent and needs review. I apologize for the AI-speak, we are working on rewriting it!
viv-lang.org

Notebooks · lib/stats/api

The entry points vp.stats calls

vp.stats (python/vipyr/_stats.py) compiles this file once through vipyr's cache and calls these defs on flat float64 arrays; Python broadcasts the arguments, applies loc and scale, and names the codes.

  • special_eval(code, a, b, x): special function number code (the SF_ codes below) at each (a[i], b[i], x[i]), the arguments it does not take ignored.
  • dist_eval(fam, what, x, s1, s2, s3): lib/stats/dist.viv's dist_value at each point.
  • dist_rvs(fam, s1, s2, s3, n, seed): n draws by inversion.
  • describe(x, ddof, method): n, mean, variance (two-pass, or Welford's when method is 1), skewness and excess kurtosis; quantiles(x, p, type).
  • ols_fit(X, y, method, tol, refine): lib/stats/linmod.viv's lstsq and the exact residuals; glm_fit(...): lib/stats/glm.viv's glm_irls, and glm_observed(...) its observed-information covariance.

Used with from stats.api import ....

Look inside this program

  • Atlas

    The program’s map: every function and which calls which.

  • There’s no recorded run of this program yet.

Shift+Enter in a cell runs it and moves to the next. Running a cell runs every cell above it too, as one program.

[1]lines 23–174