If _. is removed altogether and you get a NaN in 
your data (from external sources), that makes the
data very nasty to deal with, and imposes an overhead
on other data that has nothing to do with NaN. e.g.

   wd 'blah blah blah0'
|NaN error
|       wd'blah blah blah'
   wd 'blah blah blah1'
   NB. works, but J has to check data for NaN

In case you missed it, the following sentences in
the dictionary entry
http://www.jsoftware.com/help/dictionary/d031.htm
on _. are worth reading:

The indeterminate _. is a numeric atom. It is provided 
to aid in dealing with NaN (not a number) in data from 
external sources, and should be removed from such data 
as soon as possible.  ...

Other primitives on arguments containing _. may not produce 
correct or consistent results. In particular, the dyads 
< <: = >: > ~: -: <. >. do not produce consistent results on 
arguments containing _. , nor the verbs /: \: , nor the dyads i. i: e. -. , 
nor the monads ~. ~: , nor verbs defined in terms of these.



----- Original Message -----
From: "Mark D. Niemiec" <[EMAIL PROTECTED]>
Date: Monday, March 17, 2008 2:17
Subject: Subject: Re: [Jprogramming] Handling NaN error with #:_
To: [email protected]

> Roger Hui <[EMAIL PROTECTED]> wrote:
> To: Programming forum <[email protected]>
> Message-ID: <[EMAIL PROTECTED]>
> Content-Type: text/plain; charset=iso-8859-1
> 
> > As stated before, _. is provided to aid in dealing with NaN
> > in data from external sources, and should be removed from
> > such data as soon as possible.  To deliberately put _. 
> into your
> > data is extremely reckless.
> 
> This is true.
> 
> In this case, perhaps it might be an idea to go all the way,
> and remove _. from the parser altogether (making it a spelling error,
> and only allowing its creation from foreign sources (or perhaps 3!:2)
> since it has no legitimate use in any mainstream J primities
> (other than 128!:5) anyway. This has always been the case with
> all the other flavours of NaN, and nobody seems to mind.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to