Previous Page | Next Page

SAS Formats under Windows

RBw.d Format: Windows



Writes values real-binary (floating-point) format.
Category numeric
Width range: 2-8
Default width: 4
Decimal range: 0-10
Alignment: left
Windows specifics: native floating-point representation
See: RBw.d in SAS Language Reference: Dictionary

Syntax
Details
Examples
Example 1: Processing a Number That Is Too Large To Format
See Also

Syntax

RBw.d

w

specifies the width of the output field.

d

specifies a scaling factor. When you specify a d value, the RBw.d format multiplies the number by 10d, and then applies the real binary format to that value.


Details

The RBw.d format writes numeric data in real binary (floating-point) notation. Numeric data for scientific calculations are commonly represented in floating-point notation. (SAS stores all numeric values in floating-point notation.) A floating-point value consists of two parts: a mantissa that gives the value and an exponent that gives the value's magnitude.

Real binary is the most efficient format for representing numeric values because SAS already represents numbers this way and no conversion is needed.

For more information about Windows floating-point notation, see the Intel developer Web site.


Examples


Example 1: Processing a Number That Is Too Large To Format

When a numeric value is too large to format, as in this example

data a;
   x = 1e308;
   y = put(x, RB8.2);
   put y = hex16.;
run;

the result is

y=0000000000D1FFFF


See Also

Previous Page | Next Page | Top of Page