octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gammai->gammainc


From: Paul Kienzle
Subject: gammai->gammainc
Date: Fri, 9 Aug 2002 19:20:12 -0400

Paul Kienzle <address@hidden>

        * statistics/distributions/gamma_cdf.m: replace gammai with gammainc
        * statistics/distributions/poisson_cdf.m: Likewise.

Index: statistics/distributions/gamma_cdf.m
===================================================================
RCS file: /cvs/octave/scripts/statistics/distributions/gamma_cdf.m,v
retrieving revision 1.4
diff -c -r1.4 gamma_cdf.m
*** statistics/distributions/gamma_cdf.m        2002/05/01 06:48:35     1.4
--- statistics/distributions/gamma_cdf.m        2002/08/09 19:25:26
***************
*** 52,58 ****
  
    k = find ((x > 0) & (a > 0) & (b > 0));
    if (any (k))
!     cdf (k) = gammai (a(k), b(k) .* x(k));
    endif
  
    cdf = reshape (cdf, r, c);
--- 52,58 ----
  
    k = find ((x > 0) & (a > 0) & (b > 0));
    if (any (k))
!     cdf (k) = gammainc (b(k) .* x(k), a(k));
    endif
  
    cdf = reshape (cdf, r, c);
Index: statistics/distributions/poisson_cdf.m
===================================================================
RCS file: /cvs/octave/scripts/statistics/distributions/poisson_cdf.m,v
retrieving revision 1.5
diff -c -r1.5 poisson_cdf.m
*** statistics/distributions/poisson_cdf.m      2002/05/01 06:48:36     1.5
--- statistics/distributions/poisson_cdf.m      2002/08/09 19:25:26
***************
*** 56,62 ****
  
    k = find ((x >= 0) & (x < Inf) & (l > 0));
    if (any (k))
!     cdf(k) = 1 - gammai (floor (x(k)) + 1, l(k));
    endif
  
    cdf = reshape (cdf, r, c);
--- 56,62 ----
  
    k = find ((x >= 0) & (x < Inf) & (l > 0));
    if (any (k))
!     cdf(k) = 1 - gammainc (l(k), floor (x(k)) + 1);
    endif
  
    cdf = reshape (cdf, r, c);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]