![]() Chapter Contents |
![]() Previous |
![]() Next |
| FLOATw.d |
| Category: | Numeric |
| Syntax | |
| Syntax Description | |
| Details | |
| Comparisons | |
| Examples |
Syntax |
| FLOATw.d |
| Requirement: | w must be 4. |
| 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 may 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 Lines* | Results |
|---|---|
----+----1----+----2 |
|
3F800000 |
1 |
| *The data line is a hexadecimal representation of a binary number that is stored in IEEE form. | |
![]() Chapter Contents |
![]() Previous |
![]() Next |
![]() Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.