Previous Page | Next Page

Informats

FLOATw.d Informat



Reads a native single-precision, floating-point value and divides it by 10 raised to the dth power.
Category: Numeric

Syntax
Syntax Description
Details
Comparisons
Examples

Syntax

FLOATw.d

Syntax Description

w

specifies the width of the input field.

Requirement: w must be 4.
d

specifies the power of 10 by which to divide the value. This argument is optional.


Details

The FLOATw.d informat is useful in operating environments where a float value is not the same as a truncated double.

On the IBM mainframe systems, a four-byte floating-point number is the same as a truncated eight-byte floating-point number. However, in operating environments that use the IEEE floating-point standard, such as the IBM PC-based operating environments and most UNIX platforms, a four-byte floating-point number is not the same as a truncated double. Therefore, the RB4. informat does not produce the same results as FLOAT4. Floating-point representations other than IEEE might have this same characteristic. Values read with FLOAT4. typically come from some other external program that is running in your operating environment.


Comparisons

The following table compares the names of float notation in several programming languages:

Language Float Notation
SAS FLOAT4.
Fortran REAL*4
C float
IBM 370 ASM E
PL/I FLOAT BIN(21)


Examples

input x float4.;

Data Line* Results
----+----1----+----2

3F800000
1
* The data line is a hexadecimal representation of a binary number that is stored in IEEE form.

Previous Page | Next Page | Top of Page