changeset 14336:34af9f9ff98b

Use Octave coding conventions (double-quote " in preference to single quote ') * center.m, corr.m, cov.m, iqr.m, kendall.m, spearman.m, std.m, var.m: Use Octave coding conventions (double-quote " in preference to single quote ')
author Rik <octave@nomad.inbox5.com>
date Sun, 05 Feb 2012 15:46:02 -0800
parents ce2b59a6d0e5
children a8a2d5def558
files scripts/statistics/base/center.m scripts/statistics/base/corr.m scripts/statistics/base/cov.m scripts/statistics/base/iqr.m scripts/statistics/base/kendall.m scripts/statistics/base/spearman.m scripts/statistics/base/std.m scripts/statistics/base/var.m
diffstat 8 files changed, 13 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/statistics/base/center.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/center.m	Sun Feb 05 15:46:02 2012 -0800
@@ -70,7 +70,7 @@
 %!assert(center (int8 ([1,2,3])), [-1,0,1])
 %!assert(center (logical ([1, 0, 0, 1])), [0.5, -0.5, -0.5, 0.5])
 %!assert(center (ones (3,2,0,2)), zeros (3,2,0,2))
-%!assert(center (ones (3,2,0,2, 'single')), zeros (3,2,0,2, 'single'))
+%!assert(center (ones (3,2,0,2, "single")), zeros (3,2,0,2, "single"))
 %!assert(center (magic (3)), [3,-4,1;-2,0,2;-1,4,-3])
 %!assert(center ([1 2 3; 6 5 4], 2), [-1 0 1; 1 0 -1])
 
--- a/scripts/statistics/base/corr.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/corr.m	Sun Feb 05 15:46:02 2012 -0800
@@ -56,7 +56,7 @@
 
   ## Special case, scalar is always 100% correlated with itself
   if (isscalar (x))
-    if (isa (x, 'single'))
+    if (isa (x, "single"))
       retval = single (1);
     else
       retval = 1;
--- a/scripts/statistics/base/cov.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/cov.m	Sun Feb 05 15:46:02 2012 -0800
@@ -86,7 +86,7 @@
 
   ## Special case, scalar has zero covariance
   if (isscalar (x))
-    if (isa (x, 'single'))
+    if (isa (x, "single"))
       c = single (0);
     else
       c = 0;
--- a/scripts/statistics/base/iqr.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/iqr.m	Sun Feb 05 15:46:02 2012 -0800
@@ -60,8 +60,8 @@
   ## can take a matrix, rather than just a vector argument.
   n = sz(dim);
   sz(dim) = 1;
-  if (isa (x, 'single'))
-    y = zeros (sz, 'single');
+  if (isa (x, "single"))
+    y = zeros (sz, "single");
   else
     y = zeros (sz);
   endif
--- a/scripts/statistics/base/kendall.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/kendall.m	Sun Feb 05 15:46:02 2012 -0800
@@ -99,10 +99,10 @@
     endif
   endif
 
-  if (isa (x, 'single') || isa (y, 'single'))
-    cls = 'single';
+  if (isa (x, "single") || isa (y, "single"))
+    cls = "single";
   else
-    cls = 'double';
+    cls = "double";
   endif
   r   = ranks (x);
   m   = sign (kron (r, ones (n, 1, cls)) - kron (ones (n, 1, cls), r));
--- a/scripts/statistics/base/spearman.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/spearman.m	Sun Feb 05 15:46:02 2012 -0800
@@ -69,7 +69,7 @@
   endif
 
   ## Restore class cleared by ranks
-  if (isa (x, 'single') || isa (y, 'single'))
+  if (isa (x, "single") || isa (y, "single"))
     rho = single (rho);
   endif
 
--- a/scripts/statistics/base/std.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/std.m	Sun Feb 05 15:46:02 2012 -0800
@@ -92,8 +92,8 @@
 
   n = sz(dim);
   if (n == 1 || isempty (x))
-    if (isa (x, 'single'))
-      retval = zeros (sz, 'single');
+    if (isa (x, "single"))
+      retval = zeros (sz, "single");
     else
       retval = zeros (sz);
     endif
--- a/scripts/statistics/base/var.m	Sun Feb 05 15:32:24 2012 -0800
+++ b/scripts/statistics/base/var.m	Sun Feb 05 15:46:02 2012 -0800
@@ -92,8 +92,8 @@
 
   n = sz(dim);
   if (n == 1)
-    if (isa (x, 'single'))
-      retval = zeros (sz, 'single');
+    if (isa (x, "single"))
+      retval = zeros (sz, "single");
     else
       retval = zeros (sz);
     endif