diff options
author | Rafael Laboissière <rafael@debian.org> | 2024-03-09 03:00:06 -0300 |
---|---|---|
committer | Rafael Laboissière <rafael@debian.org> | 2024-03-09 03:00:06 -0300 |
commit | 8557e3e729e345e2e785c959dd92b46aa40a395d (patch) | |
tree | 9d86c1e597adb4d5cb527fad46bb13aac52e42c0 | |
parent | a642daab2db32f52c67b97d62fbeedde751358ac (diff) |
Make the BIST for glmfit reproducible
Forwarded: https://github.com/gnu-octave/statistics/pull/139
Last-Update: 2024-03-08
Gbp-Pq: Name glmfit-reproducible-bist.patch
-rw-r--r-- | inst/glmfit.m | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/inst/glmfit.m b/inst/glmfit.m index 2e5b819..75b6d32 100644 --- a/inst/glmfit.m +++ b/inst/glmfit.m @@ -133,6 +133,7 @@ endfunction %! X = rand (50, 1); %! b_true = [0.4; 1.5]; %! mu_true = exp (b_true(1) + b_true(2) * X); +%! randp ("seed", 1); %! y = poissrnd (mu_true); %! b = glmfit(X, y, "poisson", "link", "log"); %! assert(b(1), b_true(1), 0.5); |