Home » Personal collection » Acorn hard disk » files » DomFord » RoughWork/Video3

RoughWork/Video3

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Personal collection » Acorn hard disk » files » DomFord
Filename: RoughWork/Video3
Read OK:
File size: 1A9D bytes
Load address: 0000
Exec address: 0000
File contents
   10REM SpriteTest - Interquartile range
   20REM By Dominic Ford - May 1995
   30:
   40MODE 7
   50PROCinit
   60PROCanalyse
   70PROCconclusion
   80PROClearn
   90PROCstore
  100MODE 0
  110END
  120:
  130DEFPROCanalyse
  140FOR Y=1 TO yax
  150FOR X=1 TO xax
  160PRINTTAB(3,3);FNpera;"%"
  170SYS "OS_SpriteOp",41,,SPR$,X-1,Y-1 TO ,,,,,C,T
  180bin=0
  190c%(C)=c%(C)+1
  200FOR bo=1 TO mb
  210IF col(bo)=C AND block(bo,X)>Y-6 THEN bin=bin+1:oproc=bo:PROCobject_add
  220NEXT
  230IF bin=0 THEN PROCobject_make
  240IF bin>1 THEN PROCobject_join
  250NEXT,
  260PROCmcc
  270ENDPROC
  280:
  290DEFPROCmcc
  300CM%=0
  310FOR C=1 TO 15
  320IF c%(C)>=CM% THEN CM%=c%(C):MCC$=CNA$(C):MCC%=C
  330NEXT
  340ENDPROC
  350:
  360DEFPROCinit
  370ON ERROR MODE 0:REPORT:PRINT" at line ";ERL:END
  380SYS "OS_ChangeDynamicArea",3,&8000
  390PRINTCHR$(129);CHR$(141);SPC(3)"Sprite Recognition by D Ford"
  400PRINTCHR$(129);CHR$(141);SPC(3)"Sprite Recognition by D Ford"
  410VDU 28,0,24,39,3,135
  420PRINT"Filing System: (R)am"'SPC(15)" (A)DFS"'SPC(15)" (S)erver"'SPC(15)" (V)ideo Camera"
  430REPEAT
  440K$=GET$
  450UNTIL INSTR("rRaAsSvV",K$)<>0
  460IF K$="S" OR K$="s" THEN PROCserver
  470IF K$="A" OR K$="a" THEN PROCadfs
  480IF K$="R" OR K$="r" THEN *RAM
  490IF K$="V" OR K$="v" THEN PROCvideo
  500CLS
  510*.
  520INPUT"Sprite file name";SFILE$
  530INPUT"     Sprite name";SPR$
  540maxno=50
  550CLS
  560PRINT'"Please Wait. . ."
  570OSCLI "SLOAD "+SFILE$
  580SYS "OS_SpriteOp",40,,SPR$ TO ,,,xax,yax,H,,MDOE
  590DIMblock(maxno,xax),col(maxno),bmin(maxno,xax),CNA$(15),cols(15)
  600DIMc%(15),MCC$(15),MCC%(15),CM%(15),iw%(xax)
  610mb=0
  620FOR C=0 TO 15
  630READ CNA$(C),cols(C)
  640NEXT
  650ENDPROC
  660:
  670DEFPROCserver
  680INPUT"     Server name";NAME$
  690OSCLI"I AM "+NAME$
  700ENDPROC
  710:
  720DEFPROCadfs
  730PRINTSPC(8)"Insert Graphic Data Disc"''SPC(14)"Press SPACE"
  740REPEAT UNTIL INKEY(-99)
  750*ADFS
  760*MOUNT
  770ENDPROC
  780:
  790DEFPROCvideo
  800PRINT"Function not available"
  810STOP
  820ENDPROC
  830:
  840DEFPROCobject_make
  850IF mb=maxno THEN PRINT'"I am going to need more objects."
  860mb=mb+1
  870col(mb)=C
  880FOR Xwr=X-5 TO X+5
  890IF Xwr<0 OR Xwr>xax THEN NEXT:ENDPROC
  900block(mb,Xwr)=Y
  910bmin(mb,Xwr)=Y
  920NEXT
  930ENDPROC
  940:
  950DEFPROCobject_add
  960FOR Xwr=X-5 TO X+5
  970IF Xwr<0 OR Xwr>xax THEN NEXT:ENDPROC
  980block(oproc,Xwr)=Y
  990IF bmin(oproc,Xwr)=0 THEN bmin(oproc,Xwr)=Y
 1000NEXT
 1010ENDPROC
 1020:
 1030DEFPROCobject_join
 1040FOR ob=1 TO mb
 1050IF col(ob)=C AND block(ob,X)>=Y-5 THEN PROCadditon
 1060NEXT
 1070FOR ob=1 TO mb
 1080IF col(ob)=C AND ob<>oproc AND block(ob,X)>=Y-5 THEN PROCgetridofit
 1090NEXT:oproc=-1
 1100ENDPROC
 1110:
 1120DEFPROCadditon
 1130IF oproc=-1 THEN oproc=ob
 1140FOR xscan=0 TO xax-1
 1150IF block(ob,xscan)>block(oproc,xscan) THEN block(oproc,xscan)=block(ob,xscan)
 1160IF bmin(ob,xscan)<bmin(oproc,xscan) THEN bmin(oproc,xscan)=bmin(ob,xscan)
 1170NEXT
 1180ENDPROC
 1190:
 1200DEFPROCgetridofit
 1210FOR groi=ob+1 TO mb
 1220FOR groil=0 TO xax-1
 1230block(groi,groil)=block(groi-1,groil)
 1240bmin(groi,groil)=bmin(groi-1,groil)
 1250NEXT
 1260col(groi)=col(groi-1)
 1270NEXT
 1280mb=mb-1
 1290ENDPROC
 1300:
 1310DEFPROCgetdata
 1320file=OPENIN "<Obey$Dir>.Objects"
 1330INPUT#file,noobs%
 1340DIMob%(noobs%+2,maxno),prob%(noobs%+2,maxno),coobs%(noobs%+2,maxno),name$(noobs%+2),mb(noobs%+2)
 1350FOR obget=0 TO noobs%
 1360INPUT#file,name$(obget),mb(obget)
 1370FOR oblop=1 TO mb(obget)
 1380INPUT#file,ob%(obget,oblop),coobs%(obget,oblop),prob%(obget,oblop)
 1390NEXT,
 1400CLOSE#file
 1410ENDPROC
 1420:
 1430DEFPROCsavedata
 1440file=OPENOUT "<Obey$Dir>.Objects"
 1450PRINT#file,noobs%
 1460FOR obget=0 TO noobs%
 1470PRINT#file,name$(obget),mb(obget)
 1480FOR oblop=1 TO mb(obget)
 1490PRINT#file,ob%(obget,oblop),coobs%(obget,oblop),prob%(obget,oblop)
 1500NEXT,
 1510CLOSE#file
 1520ENDPROC
 1530:
 1540DEFPROCconclusion
 1550PROCgetdata
 1560PROCcolcheck
 1570PROCiqrcheck
 1580smax=-9999999:obname$=""
 1590FOR obscan=0 TO noobs%
 1600IF mb(obscan)<>0 THEN score%(obscan)=ABS(score%(obscan)/mb(obscan)) ELSE score%(obscan)=0
 1610IF smax<score%(obscan) THEN snum=obscan:smax=score%(obscan):obname$=name$(obscan)
 1620PRINTobscan,name$(obscan),score%(obscan)
 1630NEXT
 1640ENDPROC
 1650:
 1660DEFPROCcolcheck
 1670DIMscore%(noobs%+2)
 1680FOR picobs=1 TO mb
 1690FOR cclude=0 TO noobs%
 1700FOR obscan=1 TO mb(cclude)
 1710IF(coobs%(cclude,obscan) AND 2^(col(picobs)+1))<>0 THEN score%(cclude)=score%(cclude)-prob%(cclude,obscan)
 1720NEXT,,
 1730ENDPROC
 1740:
 1750DEFPROCiqrcheck
 1760FOR picobs=1 TO mb
 1770iqr=FNiqr(picobs)
 1780FOR cclude=0 TO noobs%
 1790FOR obscan=1 TO mb(cclude)
 1800score%(cclude)=score%(cclude)+(1/(prob%(cclude,obscan)+.01))*ABS(iqr-ob%(cclude,obscan))-0.5*prob%(cclude,obscan)
 1810NEXT,,
 1820ENDPROC
 1830:
 1840DEFPROCbonds
 1850FOR cclude=1 TO mb(snum)
 1860del=FALSE
 1870REPEAT
 1880prob%(snum,cclude)=prob%(snum,cclude)+FNpup
 1890IF prob%(snum,cclude)<=0 THEN PROCgetrid:del=TRUE
 1900UNTIL del=FALSE OR cclude=mb(snum)
 1910NEXT
 1920ENDPROC
 1930:
 1940DEFPROClearn
 1950PRINT'"Is it a ";obname$;:PROCask
 1960IF A$="N" THEN INPUT"What was it then";obnamen$:PROCrethink
 1970PRINT'"Was it a ";MCC$;" ";obname$;:PROCask
 1980IF A$="N" THEN PROCrecolour
 1990FOR cclude=1 TO mb(snum)
 2000prob%(snum,cclude)=prob%(snum,cclude)+0.25
 2010NEXT
 2020PROCbonds
 2030ENDPROC
 2040:
 2050DEFPROCrecolour
 2060PROCcolourtable
 2070REPEAT
 2080A$=GET$
 2090UNTIL ASC(A$)>64 AND ASC(A$)<70
 2100MCC%=ASC(A$)-64
 2110MCC$=CNA$(MCC%)
 2120ENDPROC
 2130:
 2140DEFPROCcolourtable
 2150MODE 12
 2160*<Obey$Dir>.!Pallete
 2170PRINT"What colour was it then:"
 2180FORc=0TO15
 2190COLOUR 128:PRINTCHR$(c+64);" ";
 2200COLOUR c+128
 2210PRINT;"          ";
 2220NEXT
 2230ENDPROC
 2240:
 2250DEFPROCrethink
 2260CLS
 2270PRINT"Please Wait. . ."'
 2280PROCbonds
 2290obname$=obnamen$
 2300REPEAT
 2310err=FALSE
 2320obname$=" "+obname$+" "
 2330FOR c=2 TO LEN(obname$)-1
 2340IF (FNrt<97) AND (FNrt<>32) THEN obname$=LEFT$(obname$,c-1)+CHR$(FNrt+32)+RIGHT$(obname$,LEN(obname$)-c)
 2350IF (FNrt<97 OR FNrt>122) AND FNrt<>32 THEN err=TRUE
 2360NEXT
 2370obname$=MID$(obname$,2,LEN(obname$)-2)
 2380IF err=TRUE THEN PROCreask
 2390UNTIL err=FALSE
 2400FOR ono=0 TO noobs%
 2410IF name$(ono)=obname$ THEN snum=ono:err=TRUE
 2420NEXT
 2430IF err=FALSE THEN PROCnewob
 2440ENDPROC
 2450:
 2460DEFPROCreask
 2470PRINT'"Object names can only contain letters. Please re-type the name"'
 2480INPUT"What was it then";obname$
 2490ENDPROC
 2500:
 2510DEFPROCnewob
 2520noobs%=noobs%+1
 2530mb(noobs%)=mb
 2540name$(noobs%)=obname$
 2550FOR ono=1 TO mb
 2560ob%(noobs%,ono)=FNiqr(ono)
 2570coobs%(noobs%,ono)=cols(col(ono))
 2580prob%(noobs%,ono)=2
 2590NEXT
 2600snum=noobs%
 2610ENDPROC
 2620:
 2630DEFPROCask
 2640PRINT;" (Y/N) ";
 2650REPEAT
 2660A$=GET$
 2670UNTIL INSTR("YyNn",A$)<>0
 2680IF A$="Y" OR A$="y"THEN PRINT"Yes":A$="Y" ELSE PRINT"No":A$="N"
 2690ENDPROC
 2700:
 2710DEFPROCgetrid
 2720mb(snum)=mb(snum)-1
 2730FOR obno=cclude TO mb(snum)
 2740ob%(obno,snum)=ob%(obno+1,snum)
 2750coobs%(obno,snum)=coobs%(obno+1,snum)
 2760prob%(obno,snum)=prob%(obno+1,snum)
 2770NEXT
 2780ENDPROC
 2790:
 2800DEFPROCstore
 2810MODE 12
 2820*<Obey$Dir>.!Pallete
 2830OSCLI"SCHOOSE "+SPR$
 2840PLOT &ED,0,0
 2850PRINT"Do you want me to learn from this sprite";:PROCask
 2860IF A$="N" THEN ENDPROC
 2870PRINT"Please wait. . .";
 2880PROCsavedata
 2890ENDPROC
 2900:
 2910DEFFNiqr(ono)
 2920dva=0
 2930FOR xt=0 TO xax-1
 2940IF block(ono,xt)>bmin(ono,xt) THEN PROCaddiqr:dva=dva+1
 2950NEXT
 2960=iw%(INT(dva*.75))/iw%(INT(dva*.25))
 2970:
 2980DEFPROCaddiqr
 2990FOR xs=0 TO dva
 3000IF FNdif>=iw%(xs) THEN pos=xs
 3010NEXT
 3020FOR s=pos+1 TO dva
 3030iw%(xs-1)=iw%(xs)
 3040NEXT
 3050iw%(pos)=FNdif
 3060ENDPROC
 3070:
 3080DEFFNdif=block(ono,xt)-bmin(ono,xt)
 3090:
 3100DEFFNpup
 3110xs=0
 3120FOR ono=1 TO mb
 3130xt=0
 3140iqr=FNiqr(ono)
 3150IF iqr<=ob%(snum,cclude) THEN xt=(iqr/ob%(snum,cclude))*1.5
 3160IF iqr>ob%(snum,cclude) THEN xt=(ob%(snum,cclude)/iqr)*1.5
 3170IF (2^(col(ono)+1) AND coobs%(snum,cclude)) THEN xt=xt+.25
 3180IF col(ono)=MCC% THEN xt=xt+.25
 3190IF xt>xs THEN xs=xt
 3200NEXT
 3210=xs-1
 3220:
 3230DEFFNrt=ASC(MID$(obname$,c,1))
 3240:
 3250DEFFNpera=INT((100/(xax*yax))*((X-1)+(Y-1)*xax))
 3260:
 3270DATA "white",3,"light grey",7,"medium grey",14,"dark grey",28,"very dark grey",240
 3280DATA "extremely dark grey",240,"light black",240,"black",240
 3290DATA "dark blue",8448,"yellow",4608,"green",1024,"red",18432
 3300DATA "light yellow",4608,"dark green",8448
 3310DATA "orange",16384,"light blue",32768

&� SpriteTest - Interquartile range
 � By Dominic Ford - May 1995
:
(� 7
2	�init
<�analyse
F�conclusion
P
�learn
Z
�store
d� 0
n�
x:
�
��analyse
�� Y=1 � yax
�� X=1 � xax
��3,3);�pera;"%"
�0ș "OS_SpriteOp",41,,SPR$,X-1,Y-1 � ,,,,,C,T
�	bin=0
�c%(C)=c%(C)+1
�� bo=1 � mb
�B� col(bo)=C � block(bo,X)>Y-6 � bin=bin+1:oproc=bo:�object_add
��
�� bin=0 � �object_make
�� bin>1 � �object_join
��,
�mcc
�
:
"	��mcc
,	CM%=0
6� C=1 � 15
@0� c%(C)>=CM% � CM%=c%(C):MCC$=CNA$(C):MCC%=C
J�
T�
^:
h
��init
r� � � 0:�:�" at line ";�:�
|%ș "OS_ChangeDynamicArea",3,&8000
�5�(129);�(141);�(3)"Sprite Recognition by D Ford"
�5�(129);�(141);�(3)"Sprite Recognition by D Ford"
�� 28,0,24,39,3,135
�R�"Filing System: (R)am"'�(15)" (A)DFS"'�(15)" (S)erver"'�(15)" (V)ideo Camera"
��
�K$=�
�� �"rRaAsSvV",K$)<>0
�� K$="S" � K$="s" � �server
�� K$="A" � K$="a" � �adfs
�� K$="R" � K$="r" � *RAM
�� K$="V" � K$="v" � �video
��
�*.
�"Sprite file name";SFILE$
�"     Sprite name";SPR$
maxno=50
&�
0�'"Please Wait. . ."
:� "SLOAD "+SFILE$
D2ș "OS_SpriteOp",40,,SPR$ � ,,,xax,yax,H,,MDOE
NB�block(maxno,xax),col(maxno),bmin(maxno,xax),CNA$(15),cols(15)
X.�c%(15),MCC$(15),MCC%(15),CM%(15),iw%(xax)
bmb=0
l� C=0 � 15
v� CNA$(C),cols(C)
��
��
�:
���server
��"     Server name";NAME$
��"I AM "+NAME$
��
�:
�
��adfs
�7�(8)"Insert Graphic Data Disc"''�(14)"Press SPACE"
�� � �(-99)
�	*ADFS
�
*MOUNT
�
:
��video
 �"Function not available"
*�
4�
>:
H��object_make
R5� mb=maxno � �'"I am going to need more objects."
\mb=mb+1
f
col(mb)=C
p� Xwr=X-5 � X+5
z� Xwr<0 � Xwr>xax � �:�
�block(mb,Xwr)=Y
�bmin(mb,Xwr)=Y
��
��
�:
���object_add
�� Xwr=X-5 � X+5
�� Xwr<0 � Xwr>xax � �:�
�block(oproc,Xwr)=Y
�+� bmin(oproc,Xwr)=0 � bmin(oproc,Xwr)=Y
��
��
�:
��object_join
� ob=1 � mb
-� col(ob)=C � block(ob,X)>=Y-5 � �additon
$�
.� ob=1 � mb
8<� col(ob)=C � ob<>oproc � block(ob,X)>=Y-5 � �getridofit
B�:oproc=-1
L�
V:
`
��additon
j� oproc=-1 � oproc=ob
t� xscan=0 � xax-1
~M� block(ob,xscan)>block(oproc,xscan) � block(oproc,xscan)=block(ob,xscan)
�I� bmin(ob,xscan)<bmin(oproc,xscan) � bmin(oproc,xscan)=bmin(ob,xscan)
��
��
�:
���getridofit
�� groi=ob+1 � mb
�� groil=0 � xax-1
�)block(groi,groil)=block(groi-1,groil)
�'bmin(groi,groil)=bmin(groi-1,groil)
��
�col(groi)=col(groi-1)
��
mb=mb-1

�
:

��getdata
(file=� "<Obey$Dir>.Objects"
2�#file,noobs%
<b�ob%(noobs%+2,maxno),prob%(noobs%+2,maxno),coobs%(noobs%+2,maxno),name$(noobs%+2),mb(noobs%+2)
F� obget=0 � noobs%
P!�#file,name$(obget),mb(obget)
Z� oblop=1 � mb(obget)
dB�#file,ob%(obget,oblop),coobs%(obget,oblop),prob%(obget,oblop)
n�,
x
�#file
��
�:
���savedata
�file=� "<Obey$Dir>.Objects"
��#file,noobs%
�� obget=0 � noobs%
�!�#file,name$(obget),mb(obget)
�� oblop=1 � mb(obget)
�B�#file,ob%(obget,oblop),coobs%(obget,oblop),prob%(obget,oblop)
��,
�
�#file
��
�:
��conclusion
�getdata

�colcheck
"
�iqrcheck
,smax=-9999999:obname$=""
6� obscan=0 � noobs%
@T� mb(obscan)<>0 � score%(obscan)=�(score%(obscan)/mb(obscan)) � score%(obscan)=0
JQ� smax<score%(obscan) � snum=obscan:smax=score%(obscan):obname$=name$(obscan)
T(�obscan,name$(obscan),score%(obscan)
^�
h�
r:
|��colcheck
��score%(noobs%+2)
�� picobs=1 � mb
�� cclude=0 � noobs%
�� obscan=1 � mb(cclude)
�h�(coobs%(cclude,obscan) � 2^(col(picobs)+1))<>0 � score%(cclude)=score%(cclude)-prob%(cclude,obscan)
��,,
��
�:
���iqrcheck
�� picobs=1 � mb
�iqr=�iqr(picobs)
�� cclude=0 � noobs%
�� obscan=1 � mb(cclude)
sscore%(cclude)=score%(cclude)+(1/(prob%(cclude,obscan)+.01))*�(iqr-ob%(cclude,obscan))-0.5*prob%(cclude,obscan)
�,,
�
&:
0��bonds
:� cclude=1 � mb(snum)
D	del=�
N�
X.prob%(snum,cclude)=prob%(snum,cclude)+�pup
b+� prob%(snum,cclude)<=0 � �getrid:del=�
l� del=� � cclude=mb(snum)
v�
��
�:
���learn
��'"Is it a ";obname$;:�ask
�4� A$="N" � �"What was it then";obnamen$:�rethink
�(�'"Was it a ";MCC$;" ";obname$;:�ask
�� A$="N" � �recolour
�� cclude=1 � mb(snum)
�.prob%(snum,cclude)=prob%(snum,cclude)+0.25
��
�
�bonds
��
�:
��recolour
�colourtable
�
 A$=�
*� �(A$)>64 � �(A$)<70
4MCC%=�(A$)-64
>MCC$=CNA$(MCC%)
H�
R:
\��colourtable
f� 12
p*<Obey$Dir>.!Pallete
z�"What colour was it then:"
��c=0�15
�� 128:�(c+64);" ";
�� c+128
��;"          ";
��
��
�:
�
��rethink
��
��"Please Wait. . ."'
�
�bonds
�obname$=obnamen$
��
		err=�
	obname$=" "+obname$+" "
	� c=2 � �(obname$)-1
	$S� (�rt<97) � (�rt<>32) � obname$=�obname$,c-1)+�(�rt+32)+�obname$,�(obname$)-c)
	.*� (�rt<97 � �rt>122) � �rt<>32 � err=�
	8�
	B$obname$=�obname$,2,�(obname$)-2)
	L� err=� � �reask
	V� err=�
	`� ono=0 � noobs%
	j)� name$(ono)=obname$ � snum=ono:err=�
	t�
	~� err=� � �newob
	��
	�:
	���reask
	�G�'"Object names can only contain letters. Please re-type the name"'
	��"What was it then";obname$
	��
	�:
	���newob
	�noobs%=noobs%+1
	�mb(noobs%)=mb
	�name$(noobs%)=obname$
	�� ono=1 � mb
ob%(noobs%,ono)=�iqr(ono)

%coobs%(noobs%,ono)=cols(col(ono))
prob%(noobs%,ono)=2
�
(snum=noobs%
2�
<:
F	��ask
P�;" (Y/N) ";
Z�
dA$=�
n� �"YyNn",A$)<>0
x3� A$="Y" � A$="y"� �"Yes":A$="Y" � �"No":A$="N"
��
�:
���getrid
�mb(snum)=mb(snum)-1
�� obno=cclude � mb(snum)
�#ob%(obno,snum)=ob%(obno+1,snum)
�)coobs%(obno,snum)=coobs%(obno+1,snum)
�'prob%(obno,snum)=prob%(obno+1,snum)
��
��
�:
���store
�� 12
*<Obey$Dir>.!Pallete
�"SCHOOSE "+SPR$

� &ED,0,0
"5�"Do you want me to learn from this sprite";:�ask
,� A$="N" � �
6�"Please wait. . .";
@
�savedata
J�
T:
^ݤiqr(ono)
h	dva=0
r� xt=0 � xax-1
|4� block(ono,xt)>bmin(ono,xt) � �addiqr:dva=dva+1
��
�$=iw%(�(dva*.75))/iw%(�(dva*.25))
�:
���addiqr
�� xs=0 � dva
�� �dif>=iw%(xs) � pos=xs
��
�� s=pos+1 � dva
�iw%(xs-1)=iw%(xs)
��
�iw%(pos)=�dif
��
�:
$ݤdif=block(ono,xt)-bmin(ono,xt)
:
	ݤpup
&xs=0
0� ono=1 � mb
:xt=0
Diqr=�iqr(ono)
N;� iqr<=ob%(snum,cclude) � xt=(iqr/ob%(snum,cclude))*1.5
X:� iqr>ob%(snum,cclude) � xt=(ob%(snum,cclude)/iqr)*1.5
b8� (2^(col(ono)+1) � coobs%(snum,cclude)) � xt=xt+.25
l� col(ono)=MCC% � xt=xt+.25
v� xt>xs � xs=xt
��
�	=xs-1
�:
�ݤrt=�(�obname$,c,1))
�:
�/ݤpera=�((100/(xax*yax))*((X-1)+(Y-1)*xax))
�:
�S� "white",3,"light grey",7,"medium grey",14,"dark grey",28,"very dark grey",240
�=� "extremely dark grey",240,"light black",240,"black",240
�=� "dark blue",8448,"yellow",4608,"green",1024,"red",18432
�+� "light yellow",4608,"dark green",8448
�'� "orange",16384,"light blue",32768
�
00000000  0d 00 0a 26 f4 20 53 70  72 69 74 65 54 65 73 74  |...&. SpriteTest|
00000010  20 2d 20 49 6e 74 65 72  71 75 61 72 74 69 6c 65  | - Interquartile|
00000020  20 72 61 6e 67 65 0d 00  14 20 f4 20 42 79 20 44  | range... . By D|
00000030  6f 6d 69 6e 69 63 20 46  6f 72 64 20 2d 20 4d 61  |ominic Ford - Ma|
00000040  79 20 31 39 39 35 0d 00  1e 05 3a 0d 00 28 07 eb  |y 1995....:..(..|
00000050  20 37 0d 00 32 09 f2 69  6e 69 74 0d 00 3c 0c f2  | 7..2..init..<..|
00000060  61 6e 61 6c 79 73 65 0d  00 46 0f f2 63 6f 6e 63  |analyse..F..conc|
00000070  6c 75 73 69 6f 6e 0d 00  50 0a f2 6c 65 61 72 6e  |lusion..P..learn|
00000080  0d 00 5a 0a f2 73 74 6f  72 65 0d 00 64 07 eb 20  |..Z..store..d.. |
00000090  30 0d 00 6e 05 e0 0d 00  78 05 3a 0d 00 82 0d dd  |0..n....x.:.....|
000000a0  f2 61 6e 61 6c 79 73 65  0d 00 8c 0f e3 20 59 3d  |.analyse..... Y=|
000000b0  31 20 b8 20 79 61 78 0d  00 96 0f e3 20 58 3d 31  |1 . yax..... X=1|
000000c0  20 b8 20 78 61 78 0d 00  a0 14 f1 8a 33 2c 33 29  | . xax......3,3)|
000000d0  3b a4 70 65 72 61 3b 22  25 22 0d 00 aa 30 c8 99  |;.pera;"%"...0..|
000000e0  20 22 4f 53 5f 53 70 72  69 74 65 4f 70 22 2c 34  | "OS_SpriteOp",4|
000000f0  31 2c 2c 53 50 52 24 2c  58 2d 31 2c 59 2d 31 20  |1,,SPR$,X-1,Y-1 |
00000100  b8 20 2c 2c 2c 2c 2c 43  2c 54 0d 00 b4 09 62 69  |. ,,,,,C,T....bi|
00000110  6e 3d 30 0d 00 be 11 63  25 28 43 29 3d 63 25 28  |n=0....c%(C)=c%(|
00000120  43 29 2b 31 0d 00 c8 0f  e3 20 62 6f 3d 31 20 b8  |C)+1..... bo=1 .|
00000130  20 6d 62 0d 00 d2 42 e7  20 63 6f 6c 28 62 6f 29  | mb...B. col(bo)|
00000140  3d 43 20 80 20 62 6c 6f  63 6b 28 62 6f 2c 58 29  |=C . block(bo,X)|
00000150  3e 59 2d 36 20 8c 20 62  69 6e 3d 62 69 6e 2b 31  |>Y-6 . bin=bin+1|
00000160  3a 6f 70 72 6f 63 3d 62  6f 3a f2 6f 62 6a 65 63  |:oproc=bo:.objec|
00000170  74 5f 61 64 64 0d 00 dc  05 ed 0d 00 e6 1a e7 20  |t_add.......... |
00000180  62 69 6e 3d 30 20 8c 20  f2 6f 62 6a 65 63 74 5f  |bin=0 . .object_|
00000190  6d 61 6b 65 0d 00 f0 1a  e7 20 62 69 6e 3e 31 20  |make..... bin>1 |
000001a0  8c 20 f2 6f 62 6a 65 63  74 5f 6a 6f 69 6e 0d 00  |. .object_join..|
000001b0  fa 06 ed 2c 0d 01 04 08  f2 6d 63 63 0d 01 0e 05  |...,.....mcc....|
000001c0  e1 0d 01 18 05 3a 0d 01  22 09 dd f2 6d 63 63 0d  |.....:.."...mcc.|
000001d0  01 2c 09 43 4d 25 3d 30  0d 01 36 0e e3 20 43 3d  |.,.CM%=0..6.. C=|
000001e0  31 20 b8 20 31 35 0d 01  40 30 e7 20 63 25 28 43  |1 . 15..@0. c%(C|
000001f0  29 3e 3d 43 4d 25 20 8c  20 43 4d 25 3d 63 25 28  |)>=CM% . CM%=c%(|
00000200  43 29 3a 4d 43 43 24 3d  43 4e 41 24 28 43 29 3a  |C):MCC$=CNA$(C):|
00000210  4d 43 43 25 3d 43 0d 01  4a 05 ed 0d 01 54 05 e1  |MCC%=C..J....T..|
00000220  0d 01 5e 05 3a 0d 01 68  0a dd f2 69 6e 69 74 0d  |..^.:..h...init.|
00000230  01 72 1e ee 20 85 20 eb  20 30 3a f6 3a f1 22 20  |.r.. . . 0:.:." |
00000240  61 74 20 6c 69 6e 65 20  22 3b 9e 3a e0 0d 01 7c  |at line ";.:...||
00000250  25 c8 99 20 22 4f 53 5f  43 68 61 6e 67 65 44 79  |%.. "OS_ChangeDy|
00000260  6e 61 6d 69 63 41 72 65  61 22 2c 33 2c 26 38 30  |namicArea",3,&80|
00000270  30 30 0d 01 86 35 f1 bd  28 31 32 39 29 3b bd 28  |00...5..(129);.(|
00000280  31 34 31 29 3b 89 28 33  29 22 53 70 72 69 74 65  |141);.(3)"Sprite|
00000290  20 52 65 63 6f 67 6e 69  74 69 6f 6e 20 62 79 20  | Recognition by |
000002a0  44 20 46 6f 72 64 22 0d  01 90 35 f1 bd 28 31 32  |D Ford"...5..(12|
000002b0  39 29 3b bd 28 31 34 31  29 3b 89 28 33 29 22 53  |9);.(141);.(3)"S|
000002c0  70 72 69 74 65 20 52 65  63 6f 67 6e 69 74 69 6f  |prite Recognitio|
000002d0  6e 20 62 79 20 44 20 46  6f 72 64 22 0d 01 9a 16  |n by D Ford"....|
000002e0  ef 20 32 38 2c 30 2c 32  34 2c 33 39 2c 33 2c 31  |. 28,0,24,39,3,1|
000002f0  33 35 0d 01 a4 52 f1 22  46 69 6c 69 6e 67 20 53  |35...R."Filing S|
00000300  79 73 74 65 6d 3a 20 28  52 29 61 6d 22 27 89 28  |ystem: (R)am"'.(|
00000310  31 35 29 22 20 28 41 29  44 46 53 22 27 89 28 31  |15)" (A)DFS"'.(1|
00000320  35 29 22 20 28 53 29 65  72 76 65 72 22 27 89 28  |5)" (S)erver"'.(|
00000330  31 35 29 22 20 28 56 29  69 64 65 6f 20 43 61 6d  |15)" (V)ideo Cam|
00000340  65 72 61 22 0d 01 ae 05  f5 0d 01 b8 08 4b 24 3d  |era".........K$=|
00000350  be 0d 01 c2 18 fd 20 a7  22 72 52 61 41 73 53 76  |...... ."rRaAsSv|
00000360  56 22 2c 4b 24 29 3c 3e  30 0d 01 cc 1f e7 20 4b  |V",K$)<>0..... K|
00000370  24 3d 22 53 22 20 84 20  4b 24 3d 22 73 22 20 8c  |$="S" . K$="s" .|
00000380  20 f2 73 65 72 76 65 72  0d 01 d6 1d e7 20 4b 24  | .server..... K$|
00000390  3d 22 41 22 20 84 20 4b  24 3d 22 61 22 20 8c 20  |="A" . K$="a" . |
000003a0  f2 61 64 66 73 0d 01 e0  1c e7 20 4b 24 3d 22 52  |.adfs..... K$="R|
000003b0  22 20 84 20 4b 24 3d 22  72 22 20 8c 20 2a 52 41  |" . K$="r" . *RA|
000003c0  4d 0d 01 ea 1e e7 20 4b  24 3d 22 56 22 20 84 20  |M..... K$="V" . |
000003d0  4b 24 3d 22 76 22 20 8c  20 f2 76 69 64 65 6f 0d  |K$="v" . .video.|
000003e0  01 f4 05 db 0d 01 fe 06  2a 2e 0d 02 08 1e e8 22  |........*......"|
000003f0  53 70 72 69 74 65 20 66  69 6c 65 20 6e 61 6d 65  |Sprite file name|
00000400  22 3b 53 46 49 4c 45 24  0d 02 12 1c e8 22 20 20  |";SFILE$....."  |
00000410  20 20 20 53 70 72 69 74  65 20 6e 61 6d 65 22 3b  |   Sprite name";|
00000420  53 50 52 24 0d 02 1c 0c  6d 61 78 6e 6f 3d 35 30  |SPR$....maxno=50|
00000430  0d 02 26 05 db 0d 02 30  18 f1 27 22 50 6c 65 61  |..&....0..'"Plea|
00000440  73 65 20 57 61 69 74 2e  20 2e 20 2e 22 0d 02 3a  |se Wait. . ."..:|
00000450  15 ff 20 22 53 4c 4f 41  44 20 22 2b 53 46 49 4c  |.. "SLOAD "+SFIL|
00000460  45 24 0d 02 44 32 c8 99  20 22 4f 53 5f 53 70 72  |E$..D2.. "OS_Spr|
00000470  69 74 65 4f 70 22 2c 34  30 2c 2c 53 50 52 24 20  |iteOp",40,,SPR$ |
00000480  b8 20 2c 2c 2c 78 61 78  2c 79 61 78 2c 48 2c 2c  |. ,,,xax,yax,H,,|
00000490  4d 44 4f 45 0d 02 4e 42  de 62 6c 6f 63 6b 28 6d  |MDOE..NB.block(m|
000004a0  61 78 6e 6f 2c 78 61 78  29 2c 63 6f 6c 28 6d 61  |axno,xax),col(ma|
000004b0  78 6e 6f 29 2c 62 6d 69  6e 28 6d 61 78 6e 6f 2c  |xno),bmin(maxno,|
000004c0  78 61 78 29 2c 43 4e 41  24 28 31 35 29 2c 63 6f  |xax),CNA$(15),co|
000004d0  6c 73 28 31 35 29 0d 02  58 2e de 63 25 28 31 35  |ls(15)..X..c%(15|
000004e0  29 2c 4d 43 43 24 28 31  35 29 2c 4d 43 43 25 28  |),MCC$(15),MCC%(|
000004f0  31 35 29 2c 43 4d 25 28  31 35 29 2c 69 77 25 28  |15),CM%(15),iw%(|
00000500  78 61 78 29 0d 02 62 08  6d 62 3d 30 0d 02 6c 0e  |xax)..b.mb=0..l.|
00000510  e3 20 43 3d 30 20 b8 20  31 35 0d 02 76 15 f3 20  |. C=0 . 15..v.. |
00000520  43 4e 41 24 28 43 29 2c  63 6f 6c 73 28 43 29 0d  |CNA$(C),cols(C).|
00000530  02 80 05 ed 0d 02 8a 05  e1 0d 02 94 05 3a 0d 02  |.............:..|
00000540  9e 0c dd f2 73 65 72 76  65 72 0d 02 a8 1d e8 22  |....server....."|
00000550  20 20 20 20 20 53 65 72  76 65 72 20 6e 61 6d 65  |     Server name|
00000560  22 3b 4e 41 4d 45 24 0d  02 b2 12 ff 22 49 20 41  |";NAME$....."I A|
00000570  4d 20 22 2b 4e 41 4d 45  24 0d 02 bc 05 e1 0d 02  |M "+NAME$.......|
00000580  c6 05 3a 0d 02 d0 0a dd  f2 61 64 66 73 0d 02 da  |..:......adfs...|
00000590  37 f1 89 28 38 29 22 49  6e 73 65 72 74 20 47 72  |7..(8)"Insert Gr|
000005a0  61 70 68 69 63 20 44 61  74 61 20 44 69 73 63 22  |aphic Data Disc"|
000005b0  27 27 89 28 31 34 29 22  50 72 65 73 73 20 53 50  |''.(14)"Press SP|
000005c0  41 43 45 22 0d 02 e4 0e  f5 20 fd 20 a6 28 2d 39  |ACE"..... . .(-9|
000005d0  39 29 0d 02 ee 09 2a 41  44 46 53 0d 02 f8 0a 2a  |9)....*ADFS....*|
000005e0  4d 4f 55 4e 54 0d 03 02  05 e1 0d 03 0c 05 3a 0d  |MOUNT.........:.|
000005f0  03 16 0b dd f2 76 69 64  65 6f 0d 03 20 1d f1 22  |.....video.. .."|
00000600  46 75 6e 63 74 69 6f 6e  20 6e 6f 74 20 61 76 61  |Function not ava|
00000610  69 6c 61 62 6c 65 22 0d  03 2a 05 fa 0d 03 34 05  |ilable"..*....4.|
00000620  e1 0d 03 3e 05 3a 0d 03  48 11 dd f2 6f 62 6a 65  |...>.:..H...obje|
00000630  63 74 5f 6d 61 6b 65 0d  03 52 35 e7 20 6d 62 3d  |ct_make..R5. mb=|
00000640  6d 61 78 6e 6f 20 8c 20  f1 27 22 49 20 61 6d 20  |maxno . .'"I am |
00000650  67 6f 69 6e 67 20 74 6f  20 6e 65 65 64 20 6d 6f  |going to need mo|
00000660  72 65 20 6f 62 6a 65 63  74 73 2e 22 0d 03 5c 0b  |re objects."..\.|
00000670  6d 62 3d 6d 62 2b 31 0d  03 66 0d 63 6f 6c 28 6d  |mb=mb+1..f.col(m|
00000680  62 29 3d 43 0d 03 70 13  e3 20 58 77 72 3d 58 2d  |b)=C..p.. Xwr=X-|
00000690  35 20 b8 20 58 2b 35 0d  03 7a 1b e7 20 58 77 72  |5 . X+5..z.. Xwr|
000006a0  3c 30 20 84 20 58 77 72  3e 78 61 78 20 8c 20 ed  |<0 . Xwr>xax . .|
000006b0  3a e1 0d 03 84 13 62 6c  6f 63 6b 28 6d 62 2c 58  |:.....block(mb,X|
000006c0  77 72 29 3d 59 0d 03 8e  12 62 6d 69 6e 28 6d 62  |wr)=Y....bmin(mb|
000006d0  2c 58 77 72 29 3d 59 0d  03 98 05 ed 0d 03 a2 05  |,Xwr)=Y.........|
000006e0  e1 0d 03 ac 05 3a 0d 03  b6 10 dd f2 6f 62 6a 65  |.....:......obje|
000006f0  63 74 5f 61 64 64 0d 03  c0 13 e3 20 58 77 72 3d  |ct_add..... Xwr=|
00000700  58 2d 35 20 b8 20 58 2b  35 0d 03 ca 1b e7 20 58  |X-5 . X+5..... X|
00000710  77 72 3c 30 20 84 20 58  77 72 3e 78 61 78 20 8c  |wr<0 . Xwr>xax .|
00000720  20 ed 3a e1 0d 03 d4 16  62 6c 6f 63 6b 28 6f 70  | .:.....block(op|
00000730  72 6f 63 2c 58 77 72 29  3d 59 0d 03 de 2b e7 20  |roc,Xwr)=Y...+. |
00000740  62 6d 69 6e 28 6f 70 72  6f 63 2c 58 77 72 29 3d  |bmin(oproc,Xwr)=|
00000750  30 20 8c 20 62 6d 69 6e  28 6f 70 72 6f 63 2c 58  |0 . bmin(oproc,X|
00000760  77 72 29 3d 59 0d 03 e8  05 ed 0d 03 f2 05 e1 0d  |wr)=Y...........|
00000770  03 fc 05 3a 0d 04 06 11  dd f2 6f 62 6a 65 63 74  |...:......object|
00000780  5f 6a 6f 69 6e 0d 04 10  0f e3 20 6f 62 3d 31 20  |_join..... ob=1 |
00000790  b8 20 6d 62 0d 04 1a 2d  e7 20 63 6f 6c 28 6f 62  |. mb...-. col(ob|
000007a0  29 3d 43 20 80 20 62 6c  6f 63 6b 28 6f 62 2c 58  |)=C . block(ob,X|
000007b0  29 3e 3d 59 2d 35 20 8c  20 f2 61 64 64 69 74 6f  |)>=Y-5 . .addito|
000007c0  6e 0d 04 24 05 ed 0d 04  2e 0f e3 20 6f 62 3d 31  |n..$....... ob=1|
000007d0  20 b8 20 6d 62 0d 04 38  3c e7 20 63 6f 6c 28 6f  | . mb..8<. col(o|
000007e0  62 29 3d 43 20 80 20 6f  62 3c 3e 6f 70 72 6f 63  |b)=C . ob<>oproc|
000007f0  20 80 20 62 6c 6f 63 6b  28 6f 62 2c 58 29 3e 3d  | . block(ob,X)>=|
00000800  59 2d 35 20 8c 20 f2 67  65 74 72 69 64 6f 66 69  |Y-5 . .getridofi|
00000810  74 0d 04 42 0e ed 3a 6f  70 72 6f 63 3d 2d 31 0d  |t..B..:oproc=-1.|
00000820  04 4c 05 e1 0d 04 56 05  3a 0d 04 60 0d dd f2 61  |.L....V.:..`...a|
00000830  64 64 69 74 6f 6e 0d 04  6a 19 e7 20 6f 70 72 6f  |dditon..j.. opro|
00000840  63 3d 2d 31 20 8c 20 6f  70 72 6f 63 3d 6f 62 0d  |c=-1 . oproc=ob.|
00000850  04 74 15 e3 20 78 73 63  61 6e 3d 30 20 b8 20 78  |.t.. xscan=0 . x|
00000860  61 78 2d 31 0d 04 7e 4d  e7 20 62 6c 6f 63 6b 28  |ax-1..~M. block(|
00000870  6f 62 2c 78 73 63 61 6e  29 3e 62 6c 6f 63 6b 28  |ob,xscan)>block(|
00000880  6f 70 72 6f 63 2c 78 73  63 61 6e 29 20 8c 20 62  |oproc,xscan) . b|
00000890  6c 6f 63 6b 28 6f 70 72  6f 63 2c 78 73 63 61 6e  |lock(oproc,xscan|
000008a0  29 3d 62 6c 6f 63 6b 28  6f 62 2c 78 73 63 61 6e  |)=block(ob,xscan|
000008b0  29 0d 04 88 49 e7 20 62  6d 69 6e 28 6f 62 2c 78  |)...I. bmin(ob,x|
000008c0  73 63 61 6e 29 3c 62 6d  69 6e 28 6f 70 72 6f 63  |scan)<bmin(oproc|
000008d0  2c 78 73 63 61 6e 29 20  8c 20 62 6d 69 6e 28 6f  |,xscan) . bmin(o|
000008e0  70 72 6f 63 2c 78 73 63  61 6e 29 3d 62 6d 69 6e  |proc,xscan)=bmin|
000008f0  28 6f 62 2c 78 73 63 61  6e 29 0d 04 92 05 ed 0d  |(ob,xscan)......|
00000900  04 9c 05 e1 0d 04 a6 05  3a 0d 04 b0 10 dd f2 67  |........:......g|
00000910  65 74 72 69 64 6f 66 69  74 0d 04 ba 14 e3 20 67  |etridofit..... g|
00000920  72 6f 69 3d 6f 62 2b 31  20 b8 20 6d 62 0d 04 c4  |roi=ob+1 . mb...|
00000930  15 e3 20 67 72 6f 69 6c  3d 30 20 b8 20 78 61 78  |.. groil=0 . xax|
00000940  2d 31 0d 04 ce 29 62 6c  6f 63 6b 28 67 72 6f 69  |-1...)block(groi|
00000950  2c 67 72 6f 69 6c 29 3d  62 6c 6f 63 6b 28 67 72  |,groil)=block(gr|
00000960  6f 69 2d 31 2c 67 72 6f  69 6c 29 0d 04 d8 27 62  |oi-1,groil)...'b|
00000970  6d 69 6e 28 67 72 6f 69  2c 67 72 6f 69 6c 29 3d  |min(groi,groil)=|
00000980  62 6d 69 6e 28 67 72 6f  69 2d 31 2c 67 72 6f 69  |bmin(groi-1,groi|
00000990  6c 29 0d 04 e2 05 ed 0d  04 ec 19 63 6f 6c 28 67  |l).........col(g|
000009a0  72 6f 69 29 3d 63 6f 6c  28 67 72 6f 69 2d 31 29  |roi)=col(groi-1)|
000009b0  0d 04 f6 05 ed 0d 05 00  0b 6d 62 3d 6d 62 2d 31  |.........mb=mb-1|
000009c0  0d 05 0a 05 e1 0d 05 14  05 3a 0d 05 1e 0d dd f2  |.........:......|
000009d0  67 65 74 64 61 74 61 0d  05 28 1f 66 69 6c 65 3d  |getdata..(.file=|
000009e0  8e 20 22 3c 4f 62 65 79  24 44 69 72 3e 2e 4f 62  |. "<Obey$Dir>.Ob|
000009f0  6a 65 63 74 73 22 0d 05  32 11 e8 23 66 69 6c 65  |jects"..2..#file|
00000a00  2c 6e 6f 6f 62 73 25 0d  05 3c 62 de 6f 62 25 28  |,noobs%..<b.ob%(|
00000a10  6e 6f 6f 62 73 25 2b 32  2c 6d 61 78 6e 6f 29 2c  |noobs%+2,maxno),|
00000a20  70 72 6f 62 25 28 6e 6f  6f 62 73 25 2b 32 2c 6d  |prob%(noobs%+2,m|
00000a30  61 78 6e 6f 29 2c 63 6f  6f 62 73 25 28 6e 6f 6f  |axno),coobs%(noo|
00000a40  62 73 25 2b 32 2c 6d 61  78 6e 6f 29 2c 6e 61 6d  |bs%+2,maxno),nam|
00000a50  65 24 28 6e 6f 6f 62 73  25 2b 32 29 2c 6d 62 28  |e$(noobs%+2),mb(|
00000a60  6e 6f 6f 62 73 25 2b 32  29 0d 05 46 16 e3 20 6f  |noobs%+2)..F.. o|
00000a70  62 67 65 74 3d 30 20 b8  20 6e 6f 6f 62 73 25 0d  |bget=0 . noobs%.|
00000a80  05 50 21 e8 23 66 69 6c  65 2c 6e 61 6d 65 24 28  |.P!.#file,name$(|
00000a90  6f 62 67 65 74 29 2c 6d  62 28 6f 62 67 65 74 29  |obget),mb(obget)|
00000aa0  0d 05 5a 19 e3 20 6f 62  6c 6f 70 3d 31 20 b8 20  |..Z.. oblop=1 . |
00000ab0  6d 62 28 6f 62 67 65 74  29 0d 05 64 42 e8 23 66  |mb(obget)..dB.#f|
00000ac0  69 6c 65 2c 6f 62 25 28  6f 62 67 65 74 2c 6f 62  |ile,ob%(obget,ob|
00000ad0  6c 6f 70 29 2c 63 6f 6f  62 73 25 28 6f 62 67 65  |lop),coobs%(obge|
00000ae0  74 2c 6f 62 6c 6f 70 29  2c 70 72 6f 62 25 28 6f  |t,oblop),prob%(o|
00000af0  62 67 65 74 2c 6f 62 6c  6f 70 29 0d 05 6e 06 ed  |bget,oblop)..n..|
00000b00  2c 0d 05 78 0a d9 23 66  69 6c 65 0d 05 82 05 e1  |,..x..#file.....|
00000b10  0d 05 8c 05 3a 0d 05 96  0e dd f2 73 61 76 65 64  |....:......saved|
00000b20  61 74 61 0d 05 a0 1f 66  69 6c 65 3d ae 20 22 3c  |ata....file=. "<|
00000b30  4f 62 65 79 24 44 69 72  3e 2e 4f 62 6a 65 63 74  |Obey$Dir>.Object|
00000b40  73 22 0d 05 aa 11 f1 23  66 69 6c 65 2c 6e 6f 6f  |s".....#file,noo|
00000b50  62 73 25 0d 05 b4 16 e3  20 6f 62 67 65 74 3d 30  |bs%..... obget=0|
00000b60  20 b8 20 6e 6f 6f 62 73  25 0d 05 be 21 f1 23 66  | . noobs%...!.#f|
00000b70  69 6c 65 2c 6e 61 6d 65  24 28 6f 62 67 65 74 29  |ile,name$(obget)|
00000b80  2c 6d 62 28 6f 62 67 65  74 29 0d 05 c8 19 e3 20  |,mb(obget)..... |
00000b90  6f 62 6c 6f 70 3d 31 20  b8 20 6d 62 28 6f 62 67  |oblop=1 . mb(obg|
00000ba0  65 74 29 0d 05 d2 42 f1  23 66 69 6c 65 2c 6f 62  |et)...B.#file,ob|
00000bb0  25 28 6f 62 67 65 74 2c  6f 62 6c 6f 70 29 2c 63  |%(obget,oblop),c|
00000bc0  6f 6f 62 73 25 28 6f 62  67 65 74 2c 6f 62 6c 6f  |oobs%(obget,oblo|
00000bd0  70 29 2c 70 72 6f 62 25  28 6f 62 67 65 74 2c 6f  |p),prob%(obget,o|
00000be0  62 6c 6f 70 29 0d 05 dc  06 ed 2c 0d 05 e6 0a d9  |blop).....,.....|
00000bf0  23 66 69 6c 65 0d 05 f0  05 e1 0d 05 fa 05 3a 0d  |#file.........:.|
00000c00  06 04 10 dd f2 63 6f 6e  63 6c 75 73 69 6f 6e 0d  |.....conclusion.|
00000c10  06 0e 0c f2 67 65 74 64  61 74 61 0d 06 18 0d f2  |....getdata.....|
00000c20  63 6f 6c 63 68 65 63 6b  0d 06 22 0d f2 69 71 72  |colcheck.."..iqr|
00000c30  63 68 65 63 6b 0d 06 2c  1c 73 6d 61 78 3d 2d 39  |check..,.smax=-9|
00000c40  39 39 39 39 39 39 3a 6f  62 6e 61 6d 65 24 3d 22  |999999:obname$="|
00000c50  22 0d 06 36 17 e3 20 6f  62 73 63 61 6e 3d 30 20  |"..6.. obscan=0 |
00000c60  b8 20 6e 6f 6f 62 73 25  0d 06 40 54 e7 20 6d 62  |. noobs%..@T. mb|
00000c70  28 6f 62 73 63 61 6e 29  3c 3e 30 20 8c 20 73 63  |(obscan)<>0 . sc|
00000c80  6f 72 65 25 28 6f 62 73  63 61 6e 29 3d 94 28 73  |ore%(obscan)=.(s|
00000c90  63 6f 72 65 25 28 6f 62  73 63 61 6e 29 2f 6d 62  |core%(obscan)/mb|
00000ca0  28 6f 62 73 63 61 6e 29  29 20 8b 20 73 63 6f 72  |(obscan)) . scor|
00000cb0  65 25 28 6f 62 73 63 61  6e 29 3d 30 0d 06 4a 51  |e%(obscan)=0..JQ|
00000cc0  e7 20 73 6d 61 78 3c 73  63 6f 72 65 25 28 6f 62  |. smax<score%(ob|
00000cd0  73 63 61 6e 29 20 8c 20  73 6e 75 6d 3d 6f 62 73  |scan) . snum=obs|
00000ce0  63 61 6e 3a 73 6d 61 78  3d 73 63 6f 72 65 25 28  |can:smax=score%(|
00000cf0  6f 62 73 63 61 6e 29 3a  6f 62 6e 61 6d 65 24 3d  |obscan):obname$=|
00000d00  6e 61 6d 65 24 28 6f 62  73 63 61 6e 29 0d 06 54  |name$(obscan)..T|
00000d10  28 f1 6f 62 73 63 61 6e  2c 6e 61 6d 65 24 28 6f  |(.obscan,name$(o|
00000d20  62 73 63 61 6e 29 2c 73  63 6f 72 65 25 28 6f 62  |bscan),score%(ob|
00000d30  73 63 61 6e 29 0d 06 5e  05 ed 0d 06 68 05 e1 0d  |scan)..^....h...|
00000d40  06 72 05 3a 0d 06 7c 0e  dd f2 63 6f 6c 63 68 65  |.r.:..|...colche|
00000d50  63 6b 0d 06 86 15 de 73  63 6f 72 65 25 28 6e 6f  |ck.....score%(no|
00000d60  6f 62 73 25 2b 32 29 0d  06 90 13 e3 20 70 69 63  |obs%+2)..... pic|
00000d70  6f 62 73 3d 31 20 b8 20  6d 62 0d 06 9a 17 e3 20  |obs=1 . mb..... |
00000d80  63 63 6c 75 64 65 3d 30  20 b8 20 6e 6f 6f 62 73  |cclude=0 . noobs|
00000d90  25 0d 06 a4 1b e3 20 6f  62 73 63 61 6e 3d 31 20  |%..... obscan=1 |
00000da0  b8 20 6d 62 28 63 63 6c  75 64 65 29 0d 06 ae 68  |. mb(cclude)...h|
00000db0  e7 28 63 6f 6f 62 73 25  28 63 63 6c 75 64 65 2c  |.(coobs%(cclude,|
00000dc0  6f 62 73 63 61 6e 29 20  80 20 32 5e 28 63 6f 6c  |obscan) . 2^(col|
00000dd0  28 70 69 63 6f 62 73 29  2b 31 29 29 3c 3e 30 20  |(picobs)+1))<>0 |
00000de0  8c 20 73 63 6f 72 65 25  28 63 63 6c 75 64 65 29  |. score%(cclude)|
00000df0  3d 73 63 6f 72 65 25 28  63 63 6c 75 64 65 29 2d  |=score%(cclude)-|
00000e00  70 72 6f 62 25 28 63 63  6c 75 64 65 2c 6f 62 73  |prob%(cclude,obs|
00000e10  63 61 6e 29 0d 06 b8 07  ed 2c 2c 0d 06 c2 05 e1  |can).....,,.....|
00000e20  0d 06 cc 05 3a 0d 06 d6  0e dd f2 69 71 72 63 68  |....:......iqrch|
00000e30  65 63 6b 0d 06 e0 13 e3  20 70 69 63 6f 62 73 3d  |eck..... picobs=|
00000e40  31 20 b8 20 6d 62 0d 06  ea 14 69 71 72 3d a4 69  |1 . mb....iqr=.i|
00000e50  71 72 28 70 69 63 6f 62  73 29 0d 06 f4 17 e3 20  |qr(picobs)..... |
00000e60  63 63 6c 75 64 65 3d 30  20 b8 20 6e 6f 6f 62 73  |cclude=0 . noobs|
00000e70  25 0d 06 fe 1b e3 20 6f  62 73 63 61 6e 3d 31 20  |%..... obscan=1 |
00000e80  b8 20 6d 62 28 63 63 6c  75 64 65 29 0d 07 08 73  |. mb(cclude)...s|
00000e90  73 63 6f 72 65 25 28 63  63 6c 75 64 65 29 3d 73  |score%(cclude)=s|
00000ea0  63 6f 72 65 25 28 63 63  6c 75 64 65 29 2b 28 31  |core%(cclude)+(1|
00000eb0  2f 28 70 72 6f 62 25 28  63 63 6c 75 64 65 2c 6f  |/(prob%(cclude,o|
00000ec0  62 73 63 61 6e 29 2b 2e  30 31 29 29 2a 94 28 69  |bscan)+.01))*.(i|
00000ed0  71 72 2d 6f 62 25 28 63  63 6c 75 64 65 2c 6f 62  |qr-ob%(cclude,ob|
00000ee0  73 63 61 6e 29 29 2d 30  2e 35 2a 70 72 6f 62 25  |scan))-0.5*prob%|
00000ef0  28 63 63 6c 75 64 65 2c  6f 62 73 63 61 6e 29 0d  |(cclude,obscan).|
00000f00  07 12 07 ed 2c 2c 0d 07  1c 05 e1 0d 07 26 05 3a  |....,,.......&.:|
00000f10  0d 07 30 0b dd f2 62 6f  6e 64 73 0d 07 3a 19 e3  |..0...bonds..:..|
00000f20  20 63 63 6c 75 64 65 3d  31 20 b8 20 6d 62 28 73  | cclude=1 . mb(s|
00000f30  6e 75 6d 29 0d 07 44 09  64 65 6c 3d a3 0d 07 4e  |num)..D.del=...N|
00000f40  05 f5 0d 07 58 2e 70 72  6f 62 25 28 73 6e 75 6d  |....X.prob%(snum|
00000f50  2c 63 63 6c 75 64 65 29  3d 70 72 6f 62 25 28 73  |,cclude)=prob%(s|
00000f60  6e 75 6d 2c 63 63 6c 75  64 65 29 2b a4 70 75 70  |num,cclude)+.pup|
00000f70  0d 07 62 2b e7 20 70 72  6f 62 25 28 73 6e 75 6d  |..b+. prob%(snum|
00000f80  2c 63 63 6c 75 64 65 29  3c 3d 30 20 8c 20 f2 67  |,cclude)<=0 . .g|
00000f90  65 74 72 69 64 3a 64 65  6c 3d b9 0d 07 6c 1d fd  |etrid:del=...l..|
00000fa0  20 64 65 6c 3d a3 20 84  20 63 63 6c 75 64 65 3d  | del=. . cclude=|
00000fb0  6d 62 28 73 6e 75 6d 29  0d 07 76 05 ed 0d 07 80  |mb(snum)..v.....|
00000fc0  05 e1 0d 07 8a 05 3a 0d  07 94 0b dd f2 6c 65 61  |......:......lea|
00000fd0  72 6e 0d 07 9e 1e f1 27  22 49 73 20 69 74 20 61  |rn.....'"Is it a|
00000fe0  20 22 3b 6f 62 6e 61 6d  65 24 3b 3a f2 61 73 6b  | ";obname$;:.ask|
00000ff0  0d 07 a8 34 e7 20 41 24  3d 22 4e 22 20 8c 20 e8  |...4. A$="N" . .|
00001000  22 57 68 61 74 20 77 61  73 20 69 74 20 74 68 65  |"What was it the|
00001010  6e 22 3b 6f 62 6e 61 6d  65 6e 24 3a f2 72 65 74  |n";obnamen$:.ret|
00001020  68 69 6e 6b 0d 07 b2 28  f1 27 22 57 61 73 20 69  |hink...(.'"Was i|
00001030  74 20 61 20 22 3b 4d 43  43 24 3b 22 20 22 3b 6f  |t a ";MCC$;" ";o|
00001040  62 6e 61 6d 65 24 3b 3a  f2 61 73 6b 0d 07 bc 18  |bname$;:.ask....|
00001050  e7 20 41 24 3d 22 4e 22  20 8c 20 f2 72 65 63 6f  |. A$="N" . .reco|
00001060  6c 6f 75 72 0d 07 c6 19  e3 20 63 63 6c 75 64 65  |lour..... cclude|
00001070  3d 31 20 b8 20 6d 62 28  73 6e 75 6d 29 0d 07 d0  |=1 . mb(snum)...|
00001080  2e 70 72 6f 62 25 28 73  6e 75 6d 2c 63 63 6c 75  |.prob%(snum,cclu|
00001090  64 65 29 3d 70 72 6f 62  25 28 73 6e 75 6d 2c 63  |de)=prob%(snum,c|
000010a0  63 6c 75 64 65 29 2b 30  2e 32 35 0d 07 da 05 ed  |clude)+0.25.....|
000010b0  0d 07 e4 0a f2 62 6f 6e  64 73 0d 07 ee 05 e1 0d  |.....bonds......|
000010c0  07 f8 05 3a 0d 08 02 0e  dd f2 72 65 63 6f 6c 6f  |...:......recolo|
000010d0  75 72 0d 08 0c 10 f2 63  6f 6c 6f 75 72 74 61 62  |ur.....colourtab|
000010e0  6c 65 0d 08 16 05 f5 0d  08 20 08 41 24 3d be 0d  |le....... .A$=..|
000010f0  08 2a 19 fd 20 97 28 41  24 29 3e 36 34 20 80 20  |.*.. .(A$)>64 . |
00001100  97 28 41 24 29 3c 37 30  0d 08 34 11 4d 43 43 25  |.(A$)<70..4.MCC%|
00001110  3d 97 28 41 24 29 2d 36  34 0d 08 3e 13 4d 43 43  |=.(A$)-64..>.MCC|
00001120  24 3d 43 4e 41 24 28 4d  43 43 25 29 0d 08 48 05  |$=CNA$(MCC%)..H.|
00001130  e1 0d 08 52 05 3a 0d 08  5c 11 dd f2 63 6f 6c 6f  |...R.:..\...colo|
00001140  75 72 74 61 62 6c 65 0d  08 66 08 eb 20 31 32 0d  |urtable..f.. 12.|
00001150  08 70 18 2a 3c 4f 62 65  79 24 44 69 72 3e 2e 21  |.p.*<Obey$Dir>.!|
00001160  50 61 6c 6c 65 74 65 0d  08 7a 1f f1 22 57 68 61  |Pallete..z.."Wha|
00001170  74 20 63 6f 6c 6f 75 72  20 77 61 73 20 69 74 20  |t colour was it |
00001180  74 68 65 6e 3a 22 0d 08  84 0b e3 63 3d 30 b8 31  |then:".....c=0.1|
00001190  35 0d 08 8e 17 fb 20 31  32 38 3a f1 bd 28 63 2b  |5..... 128:..(c+|
000011a0  36 34 29 3b 22 20 22 3b  0d 08 98 0b fb 20 63 2b  |64);" ";..... c+|
000011b0  31 32 38 0d 08 a2 13 f1  3b 22 20 20 20 20 20 20  |128.....;"      |
000011c0  20 20 20 20 22 3b 0d 08  ac 05 ed 0d 08 b6 05 e1  |    ";..........|
000011d0  0d 08 c0 05 3a 0d 08 ca  0d dd f2 72 65 74 68 69  |....:......rethi|
000011e0  6e 6b 0d 08 d4 05 db 0d  08 de 18 f1 22 50 6c 65  |nk.........."Ple|
000011f0  61 73 65 20 57 61 69 74  2e 20 2e 20 2e 22 27 0d  |ase Wait. . ."'.|
00001200  08 e8 0a f2 62 6f 6e 64  73 0d 08 f2 14 6f 62 6e  |....bonds....obn|
00001210  61 6d 65 24 3d 6f 62 6e  61 6d 65 6e 24 0d 08 fc  |ame$=obnamen$...|
00001220  05 f5 0d 09 06 09 65 72  72 3d a3 0d 09 10 1b 6f  |......err=.....o|
00001230  62 6e 61 6d 65 24 3d 22  20 22 2b 6f 62 6e 61 6d  |bname$=" "+obnam|
00001240  65 24 2b 22 20 22 0d 09  1a 18 e3 20 63 3d 32 20  |e$+" "..... c=2 |
00001250  b8 20 a9 28 6f 62 6e 61  6d 65 24 29 2d 31 0d 09  |. .(obname$)-1..|
00001260  24 53 e7 20 28 a4 72 74  3c 39 37 29 20 80 20 28  |$S. (.rt<97) . (|
00001270  a4 72 74 3c 3e 33 32 29  20 8c 20 6f 62 6e 61 6d  |.rt<>32) . obnam|
00001280  65 24 3d c0 6f 62 6e 61  6d 65 24 2c 63 2d 31 29  |e$=.obname$,c-1)|
00001290  2b bd 28 a4 72 74 2b 33  32 29 2b c2 6f 62 6e 61  |+.(.rt+32)+.obna|
000012a0  6d 65 24 2c a9 28 6f 62  6e 61 6d 65 24 29 2d 63  |me$,.(obname$)-c|
000012b0  29 0d 09 2e 2a e7 20 28  a4 72 74 3c 39 37 20 84  |)...*. (.rt<97 .|
000012c0  20 a4 72 74 3e 31 32 32  29 20 80 20 a4 72 74 3c  | .rt>122) . .rt<|
000012d0  3e 33 32 20 8c 20 65 72  72 3d b9 0d 09 38 05 ed  |>32 . err=...8..|
000012e0  0d 09 42 24 6f 62 6e 61  6d 65 24 3d c1 6f 62 6e  |..B$obname$=.obn|
000012f0  61 6d 65 24 2c 32 2c a9  28 6f 62 6e 61 6d 65 24  |ame$,2,.(obname$|
00001300  29 2d 32 29 0d 09 4c 14  e7 20 65 72 72 3d b9 20  |)-2)..L.. err=. |
00001310  8c 20 f2 72 65 61 73 6b  0d 09 56 0b fd 20 65 72  |. .reask..V.. er|
00001320  72 3d a3 0d 09 60 14 e3  20 6f 6e 6f 3d 30 20 b8  |r=...`.. ono=0 .|
00001330  20 6e 6f 6f 62 73 25 0d  09 6a 29 e7 20 6e 61 6d  | noobs%..j). nam|
00001340  65 24 28 6f 6e 6f 29 3d  6f 62 6e 61 6d 65 24 20  |e$(ono)=obname$ |
00001350  8c 20 73 6e 75 6d 3d 6f  6e 6f 3a 65 72 72 3d b9  |. snum=ono:err=.|
00001360  0d 09 74 05 ed 0d 09 7e  14 e7 20 65 72 72 3d a3  |..t....~.. err=.|
00001370  20 8c 20 f2 6e 65 77 6f  62 0d 09 88 05 e1 0d 09  | . .newob.......|
00001380  92 05 3a 0d 09 9c 0b dd  f2 72 65 61 73 6b 0d 09  |..:......reask..|
00001390  a6 47 f1 27 22 4f 62 6a  65 63 74 20 6e 61 6d 65  |.G.'"Object name|
000013a0  73 20 63 61 6e 20 6f 6e  6c 79 20 63 6f 6e 74 61  |s can only conta|
000013b0  69 6e 20 6c 65 74 74 65  72 73 2e 20 50 6c 65 61  |in letters. Plea|
000013c0  73 65 20 72 65 2d 74 79  70 65 20 74 68 65 20 6e  |se re-type the n|
000013d0  61 6d 65 22 27 0d 09 b0  1f e8 22 57 68 61 74 20  |ame"'....."What |
000013e0  77 61 73 20 69 74 20 74  68 65 6e 22 3b 6f 62 6e  |was it then";obn|
000013f0  61 6d 65 24 0d 09 ba 05  e1 0d 09 c4 05 3a 0d 09  |ame$.........:..|
00001400  ce 0b dd f2 6e 65 77 6f  62 0d 09 d8 13 6e 6f 6f  |....newob....noo|
00001410  62 73 25 3d 6e 6f 6f 62  73 25 2b 31 0d 09 e2 11  |bs%=noobs%+1....|
00001420  6d 62 28 6e 6f 6f 62 73  25 29 3d 6d 62 0d 09 ec  |mb(noobs%)=mb...|
00001430  19 6e 61 6d 65 24 28 6e  6f 6f 62 73 25 29 3d 6f  |.name$(noobs%)=o|
00001440  62 6e 61 6d 65 24 0d 09  f6 10 e3 20 6f 6e 6f 3d  |bname$..... ono=|
00001450  31 20 b8 20 6d 62 0d 0a  00 1d 6f 62 25 28 6e 6f  |1 . mb....ob%(no|
00001460  6f 62 73 25 2c 6f 6e 6f  29 3d a4 69 71 72 28 6f  |obs%,ono)=.iqr(o|
00001470  6e 6f 29 0d 0a 0a 25 63  6f 6f 62 73 25 28 6e 6f  |no)...%coobs%(no|
00001480  6f 62 73 25 2c 6f 6e 6f  29 3d 63 6f 6c 73 28 63  |obs%,ono)=cols(c|
00001490  6f 6c 28 6f 6e 6f 29 29  0d 0a 14 17 70 72 6f 62  |ol(ono))....prob|
000014a0  25 28 6e 6f 6f 62 73 25  2c 6f 6e 6f 29 3d 32 0d  |%(noobs%,ono)=2.|
000014b0  0a 1e 05 ed 0d 0a 28 0f  73 6e 75 6d 3d 6e 6f 6f  |......(.snum=noo|
000014c0  62 73 25 0d 0a 32 05 e1  0d 0a 3c 05 3a 0d 0a 46  |bs%..2....<.:..F|
000014d0  09 dd f2 61 73 6b 0d 0a  50 10 f1 3b 22 20 28 59  |...ask..P..;" (Y|
000014e0  2f 4e 29 20 22 3b 0d 0a  5a 05 f5 0d 0a 64 08 41  |/N) ";..Z....d.A|
000014f0  24 3d be 0d 0a 6e 14 fd  20 a7 22 59 79 4e 6e 22  |$=...n.. ."YyNn"|
00001500  2c 41 24 29 3c 3e 30 0d  0a 78 33 e7 20 41 24 3d  |,A$)<>0..x3. A$=|
00001510  22 59 22 20 84 20 41 24  3d 22 79 22 8c 20 f1 22  |"Y" . A$="y". ."|
00001520  59 65 73 22 3a 41 24 3d  22 59 22 20 8b 20 f1 22  |Yes":A$="Y" . ."|
00001530  4e 6f 22 3a 41 24 3d 22  4e 22 0d 0a 82 05 e1 0d  |No":A$="N"......|
00001540  0a 8c 05 3a 0d 0a 96 0c  dd f2 67 65 74 72 69 64  |...:......getrid|
00001550  0d 0a a0 17 6d 62 28 73  6e 75 6d 29 3d 6d 62 28  |....mb(snum)=mb(|
00001560  73 6e 75 6d 29 2d 31 0d  0a aa 1c e3 20 6f 62 6e  |snum)-1..... obn|
00001570  6f 3d 63 63 6c 75 64 65  20 b8 20 6d 62 28 73 6e  |o=cclude . mb(sn|
00001580  75 6d 29 0d 0a b4 23 6f  62 25 28 6f 62 6e 6f 2c  |um)...#ob%(obno,|
00001590  73 6e 75 6d 29 3d 6f 62  25 28 6f 62 6e 6f 2b 31  |snum)=ob%(obno+1|
000015a0  2c 73 6e 75 6d 29 0d 0a  be 29 63 6f 6f 62 73 25  |,snum)...)coobs%|
000015b0  28 6f 62 6e 6f 2c 73 6e  75 6d 29 3d 63 6f 6f 62  |(obno,snum)=coob|
000015c0  73 25 28 6f 62 6e 6f 2b  31 2c 73 6e 75 6d 29 0d  |s%(obno+1,snum).|
000015d0  0a c8 27 70 72 6f 62 25  28 6f 62 6e 6f 2c 73 6e  |..'prob%(obno,sn|
000015e0  75 6d 29 3d 70 72 6f 62  25 28 6f 62 6e 6f 2b 31  |um)=prob%(obno+1|
000015f0  2c 73 6e 75 6d 29 0d 0a  d2 05 ed 0d 0a dc 05 e1  |,snum)..........|
00001600  0d 0a e6 05 3a 0d 0a f0  0b dd f2 73 74 6f 72 65  |....:......store|
00001610  0d 0a fa 08 eb 20 31 32  0d 0b 04 18 2a 3c 4f 62  |..... 12....*<Ob|
00001620  65 79 24 44 69 72 3e 2e  21 50 61 6c 6c 65 74 65  |ey$Dir>.!Pallete|
00001630  0d 0b 0e 14 ff 22 53 43  48 4f 4f 53 45 20 22 2b  |....."SCHOOSE "+|
00001640  53 50 52 24 0d 0b 18 0d  f0 20 26 45 44 2c 30 2c  |SPR$..... &ED,0,|
00001650  30 0d 0b 22 35 f1 22 44  6f 20 79 6f 75 20 77 61  |0.."5."Do you wa|
00001660  6e 74 20 6d 65 20 74 6f  20 6c 65 61 72 6e 20 66  |nt me to learn f|
00001670  72 6f 6d 20 74 68 69 73  20 73 70 72 69 74 65 22  |rom this sprite"|
00001680  3b 3a f2 61 73 6b 0d 0b  2c 10 e7 20 41 24 3d 22  |;:.ask..,.. A$="|
00001690  4e 22 20 8c 20 e1 0d 0b  36 18 f1 22 50 6c 65 61  |N" . ...6.."Plea|
000016a0  73 65 20 77 61 69 74 2e  20 2e 20 2e 22 3b 0d 0b  |se wait. . .";..|
000016b0  40 0d f2 73 61 76 65 64  61 74 61 0d 0b 4a 05 e1  |@..savedata..J..|
000016c0  0d 0b 54 05 3a 0d 0b 5e  0e dd a4 69 71 72 28 6f  |..T.:..^...iqr(o|
000016d0  6e 6f 29 0d 0b 68 09 64  76 61 3d 30 0d 0b 72 12  |no)..h.dva=0..r.|
000016e0  e3 20 78 74 3d 30 20 b8  20 78 61 78 2d 31 0d 0b  |. xt=0 . xax-1..|
000016f0  7c 34 e7 20 62 6c 6f 63  6b 28 6f 6e 6f 2c 78 74  ||4. block(ono,xt|
00001700  29 3e 62 6d 69 6e 28 6f  6e 6f 2c 78 74 29 20 8c  |)>bmin(ono,xt) .|
00001710  20 f2 61 64 64 69 71 72  3a 64 76 61 3d 64 76 61  | .addiqr:dva=dva|
00001720  2b 31 0d 0b 86 05 ed 0d  0b 90 24 3d 69 77 25 28  |+1........$=iw%(|
00001730  a8 28 64 76 61 2a 2e 37  35 29 29 2f 69 77 25 28  |.(dva*.75))/iw%(|
00001740  a8 28 64 76 61 2a 2e 32  35 29 29 0d 0b 9a 05 3a  |.(dva*.25))....:|
00001750  0d 0b a4 0c dd f2 61 64  64 69 71 72 0d 0b ae 10  |......addiqr....|
00001760  e3 20 78 73 3d 30 20 b8  20 64 76 61 0d 0b b8 1c  |. xs=0 . dva....|
00001770  e7 20 a4 64 69 66 3e 3d  69 77 25 28 78 73 29 20  |. .dif>=iw%(xs) |
00001780  8c 20 70 6f 73 3d 78 73  0d 0b c2 05 ed 0d 0b cc  |. pos=xs........|
00001790  13 e3 20 73 3d 70 6f 73  2b 31 20 b8 20 64 76 61  |.. s=pos+1 . dva|
000017a0  0d 0b d6 15 69 77 25 28  78 73 2d 31 29 3d 69 77  |....iw%(xs-1)=iw|
000017b0  25 28 78 73 29 0d 0b e0  05 ed 0d 0b ea 11 69 77  |%(xs).........iw|
000017c0  25 28 70 6f 73 29 3d a4  64 69 66 0d 0b f4 05 e1  |%(pos)=.dif.....|
000017d0  0d 0b fe 05 3a 0d 0c 08  24 dd a4 64 69 66 3d 62  |....:...$..dif=b|
000017e0  6c 6f 63 6b 28 6f 6e 6f  2c 78 74 29 2d 62 6d 69  |lock(ono,xt)-bmi|
000017f0  6e 28 6f 6e 6f 2c 78 74  29 0d 0c 12 05 3a 0d 0c  |n(ono,xt)....:..|
00001800  1c 09 dd a4 70 75 70 0d  0c 26 08 78 73 3d 30 0d  |....pup..&.xs=0.|
00001810  0c 30 10 e3 20 6f 6e 6f  3d 31 20 b8 20 6d 62 0d  |.0.. ono=1 . mb.|
00001820  0c 3a 08 78 74 3d 30 0d  0c 44 11 69 71 72 3d a4  |.:.xt=0..D.iqr=.|
00001830  69 71 72 28 6f 6e 6f 29  0d 0c 4e 3b e7 20 69 71  |iqr(ono)..N;. iq|
00001840  72 3c 3d 6f 62 25 28 73  6e 75 6d 2c 63 63 6c 75  |r<=ob%(snum,cclu|
00001850  64 65 29 20 8c 20 78 74  3d 28 69 71 72 2f 6f 62  |de) . xt=(iqr/ob|
00001860  25 28 73 6e 75 6d 2c 63  63 6c 75 64 65 29 29 2a  |%(snum,cclude))*|
00001870  31 2e 35 0d 0c 58 3a e7  20 69 71 72 3e 6f 62 25  |1.5..X:. iqr>ob%|
00001880  28 73 6e 75 6d 2c 63 63  6c 75 64 65 29 20 8c 20  |(snum,cclude) . |
00001890  78 74 3d 28 6f 62 25 28  73 6e 75 6d 2c 63 63 6c  |xt=(ob%(snum,ccl|
000018a0  75 64 65 29 2f 69 71 72  29 2a 31 2e 35 0d 0c 62  |ude)/iqr)*1.5..b|
000018b0  38 e7 20 28 32 5e 28 63  6f 6c 28 6f 6e 6f 29 2b  |8. (2^(col(ono)+|
000018c0  31 29 20 80 20 63 6f 6f  62 73 25 28 73 6e 75 6d  |1) . coobs%(snum|
000018d0  2c 63 63 6c 75 64 65 29  29 20 8c 20 78 74 3d 78  |,cclude)) . xt=x|
000018e0  74 2b 2e 32 35 0d 0c 6c  1f e7 20 63 6f 6c 28 6f  |t+.25..l.. col(o|
000018f0  6e 6f 29 3d 4d 43 43 25  20 8c 20 78 74 3d 78 74  |no)=MCC% . xt=xt|
00001900  2b 2e 32 35 0d 0c 76 13  e7 20 78 74 3e 78 73 20  |+.25..v.. xt>xs |
00001910  8c 20 78 73 3d 78 74 0d  0c 80 05 ed 0d 0c 8a 09  |. xs=xt.........|
00001920  3d 78 73 2d 31 0d 0c 94  05 3a 0d 0c 9e 19 dd a4  |=xs-1....:......|
00001930  72 74 3d 97 28 c1 6f 62  6e 61 6d 65 24 2c 63 2c  |rt=.(.obname$,c,|
00001940  31 29 29 0d 0c a8 05 3a  0d 0c b2 2f dd a4 70 65  |1))....:.../..pe|
00001950  72 61 3d a8 28 28 31 30  30 2f 28 78 61 78 2a 79  |ra=.((100/(xax*y|
00001960  61 78 29 29 2a 28 28 58  2d 31 29 2b 28 59 2d 31  |ax))*((X-1)+(Y-1|
00001970  29 2a 78 61 78 29 29 0d  0c bc 05 3a 0d 0c c6 53  |)*xax))....:...S|
00001980  dc 20 22 77 68 69 74 65  22 2c 33 2c 22 6c 69 67  |. "white",3,"lig|
00001990  68 74 20 67 72 65 79 22  2c 37 2c 22 6d 65 64 69  |ht grey",7,"medi|
000019a0  75 6d 20 67 72 65 79 22  2c 31 34 2c 22 64 61 72  |um grey",14,"dar|
000019b0  6b 20 67 72 65 79 22 2c  32 38 2c 22 76 65 72 79  |k grey",28,"very|
000019c0  20 64 61 72 6b 20 67 72  65 79 22 2c 32 34 30 0d  | dark grey",240.|
000019d0  0c d0 3d dc 20 22 65 78  74 72 65 6d 65 6c 79 20  |..=. "extremely |
000019e0  64 61 72 6b 20 67 72 65  79 22 2c 32 34 30 2c 22  |dark grey",240,"|
000019f0  6c 69 67 68 74 20 62 6c  61 63 6b 22 2c 32 34 30  |light black",240|
00001a00  2c 22 62 6c 61 63 6b 22  2c 32 34 30 0d 0c da 3d  |,"black",240...=|
00001a10  dc 20 22 64 61 72 6b 20  62 6c 75 65 22 2c 38 34  |. "dark blue",84|
00001a20  34 38 2c 22 79 65 6c 6c  6f 77 22 2c 34 36 30 38  |48,"yellow",4608|
00001a30  2c 22 67 72 65 65 6e 22  2c 31 30 32 34 2c 22 72  |,"green",1024,"r|
00001a40  65 64 22 2c 31 38 34 33  32 0d 0c e4 2b dc 20 22  |ed",18432...+. "|
00001a50  6c 69 67 68 74 20 79 65  6c 6c 6f 77 22 2c 34 36  |light yellow",46|
00001a60  30 38 2c 22 64 61 72 6b  20 67 72 65 65 6e 22 2c  |08,"dark green",|
00001a70  38 34 34 38 0d 0c ee 27  dc 20 22 6f 72 61 6e 67  |8448...'. "orang|
00001a80  65 22 2c 31 36 33 38 34  2c 22 6c 69 67 68 74 20  |e",16384,"light |
00001a90  62 6c 75 65 22 2c 33 32  37 36 38 0d ff           |blue",32768..|
00001a9d