octave-maintainers
[Top][All Lists]
Advanced

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

Patch to replace deprecated and removed function calls


From: Alois Schlögl
Subject: Patch to replace deprecated and removed function calls
Date: Thu, 29 Apr 2010 16:31:20 +0200
User-agent: Thunderbird 2.0.0.24 (X11/20100411)

The attached patch replaces calls to deprecated and removed functions.


Regards,
   Alois

diff -r c1111769f595 scripts/image/brighten.m
--- a/scripts/image/brighten.m  Wed Apr 28 17:19:37 2010 -0400
+++ b/scripts/image/brighten.m  Thu Apr 29 15:48:13 2010 +0200
@@ -44,7 +44,7 @@
     if (ishandle (m))
       h = m;
       m = get (h, "colormap");
-    elseif (! is_matrix (m) || size (m, 2) != 3)
+    elseif (! ismatrix (m) || size (m, 2) != 3)
       error ("brighten: first argument must be an Nx3 matrix or a handle");
     endif
   else
diff -r c1111769f595 scripts/statistics/tests/cor_test.m
--- a/scripts/statistics/tests/cor_test.m       Wed Apr 28 17:19:37 2010 -0400
+++ b/scripts/statistics/tests/cor_test.m       Thu Apr 29 15:48:13 2010 +0200
@@ -93,7 +93,7 @@
     t.params = df;
     t.stat = sqrt (df) .* r / sqrt (1 - r.^2);
     t.dist = "t";
-    cdf  = t_cdf (t.stat, df);
+    cdf  = tcdf (t.stat, df);
   elseif (m == "k")
     tau = kendall (X, Y);
     t.method = "Kendall's rank correlation tau";
diff -r c1111769f595 scripts/statistics/tests/t_test.m
--- a/scripts/statistics/tests/t_test.m Wed Apr 28 17:19:37 2010 -0400
+++ b/scripts/statistics/tests/t_test.m Thu Apr 29 15:48:13 2010 +0200
@@ -58,7 +59,7 @@
   n   = length (x);
   df  = n - 1;
   t   = sqrt (n) * (sum (x) / n - m) / std (x);
-  cdf = t_cdf (t, df);
+  cdf = tcdf (t, df);
 
   if (nargin == 2)
     alt  = "!=";
diff -r c1111769f595 scripts/statistics/tests/t_test_2.m
--- a/scripts/statistics/tests/t_test_2.m       Wed Apr 28 17:19:37 2010 -0400
+++ b/scripts/statistics/tests/t_test_2.m       Thu Apr 29 15:48:13 2010 +0200
@@ -59,7 +60,7 @@
   mu_y = sum (y) / n_y;
   v    = sumsq (x - mu_x) + sumsq (y - mu_y);
   t    = (mu_x - mu_y) * sqrt ((n_x * n_y * df) / (v * (n_x + n_y)));
-  cdf  = t_cdf (t, df);
+  cdf  = tcdf (t, df);
 
   if (nargin == 2)
     alt = "!=";
diff -r c1111769f595 scripts/statistics/tests/t_test_regression.m
--- a/scripts/statistics/tests/t_test_regression.m      Wed Apr 28 17:19:37 
2010 -0400
+++ b/scripts/statistics/tests/t_test_regression.m      Thu Apr 29 15:48:13 
2010 +0200
@@ -78,7 +78,7 @@
   [b, v] = ols (y, X);
   df     = T - k;
   t      = (R * b - r) / sqrt (v * R * inv (X' * X) * R');
-  cdf    = t_cdf (t, df);
+  cdf    = tcdf (t, df);
 
   if (strcmp (alt, "!=") || strcmp (alt, "<>"))
     pval = 2 * min (cdf, 1 - cdf);
diff -r c1111769f595 scripts/statistics/tests/welch_test.m
--- a/scripts/statistics/tests/welch_test.m     Wed Apr 28 17:19:37 2010 -0400
+++ b/scripts/statistics/tests/welch_test.m     Thu Apr 29 15:48:13 2010 +0200
@@ -60,7 +60,7 @@
   c    = v_x / (v_x + v_y);
   df   = 1 / (c^2 / (n_x - 1) + (1 - c)^2 / (n_y - 1));
   t    = (mu_x - mu_y) / sqrt (v_x + v_y);
-  cdf  = t_cdf (t, df);
+  cdf  = tcdf (t, df);
 
   if (nargin == 2)
     alt  = "!=";


reply via email to

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