[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
getting masks
From: |
John W. Eaton |
Subject: |
getting masks |
Date: |
Thu, 27 May 1999 22:19:56 -0500 (CDT) |
On 24-May-1999, Artur Jorge Azevedo Carvalho <address@hidden> wrote:
| hi! how can i do in an oct file the following:
| a=[
| 1.1 1.2 3.2
| 1.4 0.0 2.3
| 6.3 -5.1 1.1
| ]
| a!=0 to give
| [
| 1 1 1
| 1 0 1
| 1 1 1
| ]
|
| the best way i've found to do this was:
| a=Matrix(!!a);
|
| to give the same result, but it has to exist a better way to do this...
There is no special function for this in the 2.0.x Octave sources.
You have to use loops.
jwe
- getting masks, Artur Jorge Azevedo Carvalho, 1999/05/24
- getting masks, Dirk Eddelbuettel, 1999/05/24
- getting masks,
John W. Eaton <=