[Top][All Lists]

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

Re: max() and min() of nan/inf

From: Thomas Walter
Subject: Re: max() and min() of nan/inf
Date: Fri, 24 Sep 1999 10:44:46 +0200

>>>>> "John" == John W Eaton <address@hidden> writes:


    John> Why not just add an optional parameter to min, max, etc. that says to
    John> ignore NaNs?

    John>   Y = min (X, "ignore_nan");

A small suggestion:
To prevent changing existing code it may be usefull to implement this
behaviour using a global flag.

    John> Some questions:

    John>   * If a vector is all NaNs, should the result be [] or NaN?

    John>   * If a matrix has a column that is all NaNs, what should the result
    John>     be for that column?  I'd say NaN, since an individual matrix
    John>     element can't be [].  Then for consistency, the answer for the
    John>     previous question should probably also be NaN.

Hmm, I think 'NaN'.

    John> jwe

Bye the way, the paper '' someone suggested to read is really


Latest news:
Einbruch bei Microsoft, Bill Gates hat Windows offen gelassen.

Dipl. Phys. Thomas Walter
Inst. f. Physiklische Chemie II
Egerlandstr. 3                          Tel.: ++9131-85 27326 / 27330
91058 Erlangen, Germany                 email: address@hidden

Octave is freely available under the terms of the GNU GPL.  To ensure
that development continues, see
Instructions for unsubscribing:

reply via email to

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