Re: Missing Data Programming Contest [message #66002 is a reply to message #65998] |
Wed, 08 April 2009 07:27   |
R.Bauer
Messages: 1424 Registered: November 1998
|
Senior Member |
|
|
David Fanning schrieb:
> Folks,
>
> I don't have time today to think about this, so I've
> decided to get you to do my thinking for me. :-)
>
> Suppose you are expecting a data array and you suspect
> the data has "missing values" in it that you wish to
> exclude from further processing. You write a keyword
> for your routine that allows the user to pass in what
> he is using for the "missing value".
>
> PRO Junker, data, MISSING_VALUE=missing_value
>
> How would you write the code to assure that this missing
> value would be excluded from further processing?
>
> You should assume:
>
> 1. The data can be any data type except complex or string.
>
> 2. The missing value *could* be !VALUES.F_NAN.
>
> 3. Unsophisticated users might be using your program,
> so, for example, they might pass in a missing value
> such as 594.32.
>
> No, this is NOT my homework! But I do need it ASAP. ;-)
>
> Cheers,
>
> David
That old tool (nearly 10 years) has some more parameters
http://www.fz-juelich.de/icg/icg-1/idl_icglib/idl_source/idl _work/rb_lib/def_valid_for_param.pro
example at
http://www.fz-juelich.de/icg/icg-1/idl_icglib/idl_source/idl _html/examples/def_valid_for_param_example.pro.html
cheers
Reimar
|
|
|