[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #41512] Take max of sparse logical matrix
From: |
David Spies |
Subject: |
[Octave-bug-tracker] [bug #41512] Take max of sparse logical matrix |
Date: |
Sat, 08 Feb 2014 18:34:57 +0000 |
User-agent: |
Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:26.0) Gecko/20100101 Firefox/26.0 |
URL:
<http://savannah.gnu.org/bugs/?41512>
Summary: Take max of sparse logical matrix
Project: GNU Octave
Submitted by: dspyz
Submitted on: Sat 08 Feb 2014 06:34:56 PM GMT
Category: Octave Function
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Matlab Compatibility
Status: None
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: dev
Operating System: Any
_______________________________________________________
Details:
Looking at the second return value of max(a,[],2) is a way to find the index
of the first true element in each row of a.
matlab supports this when a is sparse logical, but octave gives an error:
octave:7> [i,j] = max(logical(speye(3)),[],2);
error: octave_base_value::int8_array_value(): wrong type argument 'sparse bool
matrix'
Of course you can always just convert the argument to double
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?41512>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #41512] Take max of sparse logical matrix,
David Spies <=