Indicates the end of the contents of a loop.
No options or parameters
Description
Loops are introduced by the FOR directive, where full details are given.
Options: none.
Parameters: none.
See also
Commands for: Program control.
Example
" Example 2:6.18.3 "
" Abundances of 16 grass species on 9 plots of land:
part of Table 1.1 in Digby & Kempton (1987)."
UNITS [NVALUES=16]
READ [SERIAL=yes] Abund[1...6]
15.5 2.5 7.2 0.2 1.0 0.0 2.2 33.2 0.0 0.3 6.1 0.0 6.9 0.7 0.0 0.1 :
4.0 1.0 13.1 6.1 1.6 0.0 1.5 11.7 3.6 12.0 9.5 0.0 0.0 2.5 0.3 0.4 :
1.0 28.8 6.1 37.6 0.0 0.0 7.8 1.0 0.0 0.6 2.9 0.0 0.0 5.3 1.0 1.4 :
0.0 36.8 0.3 37.0 0.0 1.3 2.7 0.0 0.0 0.0 0.0 0.0 0.0 0.7 1.5 4.5 :
19.6 0.0 9.5 0.0 0.0 0.0 0.0 48.7 0.0 0.0 4.8 0.1 0.3 1.0 2.7 0.7 :
82.7 0.0 17.2 0.0 0.0 0.0 0.0 0.1 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 :
CALCULATE LogAbund[1...6] = LOG10(Abund[1...6] + 1)
& PrsAbund[1...6] = Abund[1...6] > 0
" Form similarity matrices using 5 different methods
on suitably transformed copies of the data."
FSIMILARITY [SIMILARITY=Sjaccard] PrsAbund[]; Jaccard
& [SIMILARITY=Ssmc] PrsAbund[]; simplematching
& [SIMILARITY=Scity] LogAbund[]; cityblock
& [SIMILARITY=Secol] LogAbund[]; ecological
& [SIMILARITY=Spythag] LogAbund[]; Pythagorean
POINTER [NVALUES=7] Config
MATRIX [ROWS=16; COLUMNS=6] Config[]
LRV [ROWS=16; COLUMNS=6] Pcol
" Use PCO on each similarity matrix, to get 5 ordinations',\
of 16 points in 6 dimensions."
FOR Dsim=Sjaccard,Ssmc,Scity,Secol,Spythag; Dcpco=Config[1...5]
PCO Dsim; LRV=Pcol
CALCULATE Dcpco = Pcol[1]
ENDFOR
" Use correspondence analysis on the data, and the data
transformed to presence/absence, to get 2 more
ordinations of 16 points in 6 dimensions."
MATRIX [ROWS=16; COLUMNS=6] MatAbund
CALCULATE MatAbund$[*; 1...6] = Abund[]
CORANALYSIS [METHOD=digby] MatAbund; ROW=Config[6]
CALCULATE MatAbund = MatAbund > 0
CORANALYSIS [METHOD=digby] MatAbund; ROW=Config[7]
TEXT [VALUES=Jc,SM,CB,Ec,Py,CA,CP] Points
SYMMETRICMATRIX [ROWS=Points] MPdist
" Use multiple Procrustes analysis to compare
the 7 different ordination methods."
PCOPROCRUSTES Config; LRV=MPLRV; DISTANCE=MPdist
PRINT MPdist; FIELD=8; DECIMALS=4
CALCULATE MPscore[1,2] = MPLRV[1]$[*; 1,2]
FRAME 3; SCALING=xyequal
XAXIS 3; TITLE='Dimension 1'; LOWER=-0.55; UPPER=0.55
YAXIS 3; TITLE='Dimension 2'; LOWER=-0.55; UPPER=0.55
PEN 1; SYMBOLS=0; LABELS=Points; SIZE=1.5; COLOUR='blue'
DGRAPH [TITLE='Multiple Procrustes analysis: first two dimensions';\
WINDOW=3; KEY=0] MPscore[2]; MPscore[1]
PRINT !T('The 7 methods are plotted as the points:',\
' Jc Jaccard similarity coefficient;',\
' SM simple-matching similarity coefficient;',\
' CB city-block similarity coefficient;',\
' Ec ecological similarity coefficient;',\
' Py Pythagorean similarity coefficient;',\
' CA correspondence analysis of data;',\
' CP correspondence analysis of presence/absence.');\
JUSTIFICATION=left