Luca Favatella wrote:
Hi.
I have Octave 3.0.1 from Debian testing "Lenny" repository.
The ranks function doc says that it returns a _column_ vector, instead
the function returns a _row_ vector.
HOW TO REPPRODUCE THIS BUG
Step #1
If I type:
help ranks
I read:
"If X is a vector, return the (column) vector of ranks of X adjusted
for ties."
(it says _column_ vector)
Step #2
If I type:
"size (ranks (1:3))"
I get:
ans =
1 3
I suppose this happened when ranks was converted for use with
NDArrays... Though to me the new behavior makes more sense and I'd
propose fixing the documentation string instead with the attached patch.
This should be applied to both 3.1.51+ and 3.0.1+
D.
--
David Bateman [EMAIL PROTECTED]
Motorola Labs - Paris +33 1 69 35 48 04 (Ph)
Parc Les Algorithmes, Commune de St Aubin +33 6 72 01 06 33 (Mob)
91193 Gif-Sur-Yvette FRANCE +33 1 69 35 77 01 (Fax)
The information contained in this communication has been classified as:
[x] General Business Information
[ ] Motorola Internal Use Only
[ ] Motorola Confidential Proprietary
# HG changeset patch
# User David Bateman <[EMAIL PROTECTED]>
# Date 1219049000 -7200
# Node ID edc19e86abdc8beef8043ee9e8c36d60b0672c57
# Parent 3f8bf0c8a9c0dd76e4621fbcbe95090019a02627
Doc fix for ranks
diff --git a/scripts/ChangeLog b/scripts/ChangeLog
--- a/scripts/ChangeLog
+++ b/scripts/ChangeLog
@@ -1,3 +1,7 @@ 2008-07-29 John W. Eaton <[EMAIL PROTECTED]
+2008-08-18 David Bateman <[EMAIL PROTECTED]>
+
+ statistics/base/ranks.m: Doc fix.
+
2008-07-29 John W. Eaton <[EMAIL PROTECTED]>
* plot/axis.m (__get_tight_lims__): Use strcat instead of [].
diff --git a/scripts/statistics/base/ranks.m b/scripts/statistics/base/ranks.m
--- a/scripts/statistics/base/ranks.m
+++ b/scripts/statistics/base/ranks.m
@@ -19,11 +19,8 @@
## -*- texinfo -*-
## @deftypefn {Function File} {} ranks (@var{x}, @var{dim})
-## If @var{x} is a vector, return the (column) vector of ranks of
-## @var{x} adjusted for ties.
-##
-## If @var{x} is a matrix, do the above for along the first
-## non-singleton dimension. If the optional argument @var{dim} is
+## Return the ranks of @var{x} along the first non-singleton dimension
+## adjust for ties. If the optional argument @var{dim} is
## given, operate along this dimension.
## @end deftypefn
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Octave-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/octave-dev