Re: Need modern version of old technique to show missing values



Terence wrote:
I am rewriting the BMD program set (groans).

I have a master menu program that shows all the classes of programs by
pages and allows selection of any program out a class, to be executed
as a daughter program, returning to the menu program, and potentially
(well, the tests work) can call any selected BMD program and locate
and open appropriately, all the files each program will or might use
and open them as formatted or unformatted as required.

BUT: several programs specialise in statistics for incomplete data
("missing values").
Now: an ascii or formatted file record can be checked in each field
for "just blanks" to indicate the value is unknown.
So here I interpose a read of a character string and then process it
for "blank" fields before extracting values. But not so, in general
today, when reading binary files or unformatted file records.

Why fiddle with binary files at all if you want portability. Just use
CSV style ASCII files that are human readable, where "missing" values
would really be missing (nothing between successive commas). With the
speed of computers today, reading and parsing ASCII files is plenty fast
enough for statistics work.


In what I now have to call "the old days", you could have a positive
zero for a real value of zero and a negative real zero to indicate
this "missing value". These BMD programs utilized that trick.

Can someone suggest me, a way of coding a binary representation of a
floating-point field in such a way as I can detect that this value is
to indicate "not known", without confusing the arithmetic of the
statistics?
Obviously any user "today" will have to be able to easily produce his
data with this interior coding.
I need a coding method such that a simple test can decide if this
really is a floating point value or else the signal that the value is
"missing".
And I don't want the program to crash or have to trap conversion
errors via a program interrupt. (i.e. I need F66/F77 methods so ai
have one set of Fortran source for any compiler and target computers;
one quarter to one half of which are AT/386/486 level)

One more question:
Is the matrix MAT1(20,30) equivalent to MAT2 (20,30,1) ?

If so, I can shape all 2d and 3d matrices as 3-D, where the 2d
matrices use the limit 1 in the third dimension. This will alow me to
junk 56 individual, different subroutines and replace them with one
MAT3D(xmax,ymax,zmax), where the xmax, ymax. zmax limits are passed in
the call. The treatment (transgeneration) is algorithmically
identical, but the shapes are different.

No, no danger of rewriting an F77 compiler for the 7090; I can't
afford the upkeep of either.
.
.
.



Relevant Pages


Loading