octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #56153] Vector status of argument to any/all i


From: anonymous
Subject: [Octave-bug-tracker] [bug #56153] Vector status of argument to any/all ignored
Date: Wed, 17 Apr 2019 12:35:18 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/60.0

URL:
  <https://savannah.gnu.org/bugs/?56153>

                 Summary: Vector status of argument to any/all ignored
                 Project: GNU Octave
            Submitted by: None
            Submitted on: Wed 17 Apr 2019 04:35:16 PM UTC
                Category: Octave Function
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Missed Error or Warning
                  Status: None
             Assigned to: None
         Originator Name: buchholz
        Originator Email: address@hidden
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.0.3
        Operating System: GNU/Linux

    _______________________________________________________

Details:

The following code

++
a = reshape(1:36, 6, 6);
any(a>5, [1,2])
ans =

   1   1   1   1   1   1
--

(analogue with all)

ignores the vector status of the dim argument.

I would expect either
- octave to complain, that the argument must be a scalar, or
- do the operation over all of the indicated dimensions (as would matlab
(2018b) do), i.e. the result would be 1 in this case.

(I would prefer the second solution, it would not only reduce incompabilities,
but also be more useful.)




    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?56153>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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