RATS 10.1
RATS 10.1

Binary is the internal format used on a computer for representing numbers. It is the fastest way of reading and writing data, but probably also the least useful, since it isn’t easily portable from machine to machine or program to program and has no embedded description of the contents (10 columns with 100 rows and 1 column with 1000 look exactly the same). It is an Unlabeled format which can be used for input and output of series and matrices.

RATS Instructions

data(format=binary)

read series from binary into memory

store(convert=binary)

copy series from binary to RATS format

copy(format=binary)

write series to binary file

prtdata(format=binary)

write series from RATS format file to binary

read(format=binary)

read scalars and arrays from a binary file

write(format=binary)

write scalars and arrays to binary file

 

ORG options are required on DATA, STORE, COPY and PRTDATA.

Interface Operations

None

Details

Binary format is the fastest way of reading and writing data, as it requires no translation from characters to numbers. It also preserves the internal representation of all numbers. Speed, however, is the only real advantage it has over other formats. Its disadvantages tend to outweigh this:

 

Because the data file is not in character form, it is very difficult to determine what is on the file should you happen to forget.

It is impossible to change any number on the file without rewriting the entire file.

You cannot store dates or series labels on a binary file.

 

We don’t recommend that you use BINARY format unless it’s the only way available to communicate data to another program (running on the same type of computer). In reading binary data prepared using another program, you must be very careful to read the data back in exactly the same way as it was written.

 

Real-valued data use a 64-bit representation. This is double precision, except on machines with 64-bit single precision.

With ORG=ROWS, RATS reads (or writes) each series with a single call.

With ORG=COLS, each observation is read (written) with a single call.

 


Copyright © 2025 Thomas A. Doan