Produces percentages, using a minus sign for negative values.
Category: |
Numeric
|
Alignment: |
right
|
- w
-
specifies the width of the output field.
Default: |
6 |
Range: |
4-32 |
Tip: |
The width of the output field must account
for the minus sign ( - ), the percent sign ( % ), and a trailing blank,
whether the number is negative or positive. |
- d
-
specifies the number of digits to the right of the decimal
point in the numeric value. This argument is optional.
Range: |
0-31 |
Requirement: |
must be less than w |
The NLPCTNw.d format multiplies negative values by 100, adds a minus sign
to the beginning of the value, and adds a percent sign (%) to the end of the
formatted value.
x=-0.02;
Statements |
Results |
put x nlpctn6.; |
x=-2% |
put x percentn6.; |
x=-2% |
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.