|
CHEBYSHEV DISTANCEName:
where <y1> is the first response variable; <y2> is the second response variable; <par> is a parameter where the computed Chebyshev distance is stored; and where the <SUBSET/EXCEPT/FOR qualification> is optional.
LET A = CHEBYSHEV DISTANCE Y1 Y2 SUBSET Y1 > 0 SUBSET Y2 > 0
SKIP 25 READ IRIS.DAT Y1 TO Y4 X . LET DIST = CHEBYSHEV DISTANCE Y1 Y2 SET WRITE DECIMALS 4 TABULATE CHEBYSHEV DISTANCE Y1 Y2 X Cross Tabulate CHEBYSHEV DISTANCE (Response Variables: Y1 Y2 ) --------------------------------------------- X | CHEBYSHEV DISTA --------------------------------------------- 1.0000 | 2.2000 2.0000 | 4.0000 3.0000 | 5.1000 . XTIC OFFSET 0.2 0.2 X1LABEL GROUP ID LET NDIST = UNIQUE X XLIMITS 1 NDIST MAJOR X1TIC MARK NUMBER NDIST MINOR X1TIC MARK NUMBER 0 CHAR X LINE BLANK LABEL CASE ASIS CASE ASIS TITLE CASE ASIS TITLE OFFSET 2 . TITLE Chebyshev Distance (IRIS.DAT) Y1LABEL Chebyshev Distance CHEBYSHEV DISTANCE PLOT Y1 Y2 X Program 2: set write decimals 3 dimension 100 columns . skip 25 read iris.dat y1 y2 y3 y4 skip 0 . let z = generate matrix chebyshev distance y1 y2 y3 y4 print zThe following output is generated MATRIX Z -- 4 ROWS -- 4 COLUMNS VARIABLES--Z1 Z2 Z3 Z4 0.000 5.100 5.600 6.600 5.100 0.000 4.300 4.000 5.600 4.300 0.000 4.700 6.600 4.000 4.700 0.000
|
Privacy
Policy/Security Notice
NIST is an agency of the U.S.
Commerce Department.
Date created: 08/31/2017 |