Previous Page | Next Page

Annotate Dictionary

%SCALET Macro



Scales input coordinates based on the relationship between two ranges of minima and maxima. The scaled coordinates are plotted relative to the minima of the second range.
Variables written out: X, Y
Prerequisite: You must run the %ANNOMAC macro before using any other annotate macros. For more information, see Making the Macros Available.

Syntax
Details

Syntax

%SCALET (ptx, pty, x1, y1, x2, y2, vx1, vy1, vx2, vy2);

ptx, pty

specifies the coordinates to scale. Values can be numbers, numeric constants, or numeric variables. For details, see the Annotate X Variable.

x1, y1

specifies the minima of the original range. Values can be numbers, numeric constants, or numeric variables.

x1, y2

specifies the maxima of the original range. Values can be numbers, numeric constants, or numeric variables.

vx1, vy1

specifies the minima of the second range using numeric values. Values can be numbers, numeric constants, or numeric variables. These coordinates are also used as the origin against which the scaled point is plotted.

vx2, vy2

specifies the maxima of the second range. Values can be numbers, numeric constants, or numeric variables.


Details

The %SCALET macro reduces or enlarges Annotate graphics elements that use two-dimensional numeric coordinates. The %SCALET macro does not affect graphics elements that are drawn with text functions.

The difference between the %SCALET and %SCALE macros is that the SCALET macro plots the new coordinates with respect to minima of the second range (vx1, vy1). The %SCALE macro plots the new coordinates with respect to the origin (0, 0).

The following example uses the %SCALET macro reduces x and y coordinates by 50 percent and plots the new coordinates with respect to (50, 0), as shown in Using the %SCALET Macro to Reduce the Size of a Box:

%SCALET(x, y, 0, 0, 100, 100, 50, 0, 100, 50);

Using the %SCALET Macro to Reduce the Size of a Box

[Usng the %SCALET Macro to Reduce the Size of a Box]

Previous Page | Next Page | Top of Page