MediaWiki:Sitenotice
2026-03-12: Cocopedia.com is now using a new caching system that should make things faster. Please let me know if you encounter any new issues.

2026-03-15: MediaWiki has been reinstalled and the old database and files restored. It was pretty clogged up from being upgraded so many times since 2004. I am also testing out Cloudflare to see if it can prevent the 'bot assaults that took the site down last year.

2026-03-16: Special thanks to Don Barber for hosting a backup mirror of CoCopedia: https://cocopedia.dgb3.net

STATS

From CoCopedia - The Tandy/Radio Shack Color Computer Wiki
Jump to navigationJump to search
100 DIM A(300)
110 I=1
120 CLS: PRINT @5,"STATISTICAL ANALYSIS"
130 PRINT @64,"ENTER NUMBER,";CHR$(13);" END BY 1E30";: INPUT A(I)
140 IF A(I)=1E+30 THEN 160
150 I=I+1: PRINT @111,"": PRINT : GOTO 130
160 IF I>3 THEN 180
170 PRINT"NUST BE 3 ENTRIES OR GREATER": FOR K=1 TO 1000: NEXT X: GOTO 110
180 CLS: PRINT"SORTING";
190 C=0
200 FOR J=1 TO I-2
210 PRINT".";
220 IF A(J+1)>=A(J) THEN 240
230 B=A(J): A(J)=A(J+1): A(J+1)=B: C=1
240 NEXT J
250 IF C=1 THEN 190
260 CLS: LP=3
270 PRINT "LIST OF ORDERED DATA"
280 PRINT " N     VALUE"
290 T=0: TS=0
300 FOR J=1 TO I=1
310 T=T+A(J): TS=TS+A(J)^2
320 PRINT J;TAB(8);A(J);
330 IF J=INT(I/2) THEN PRINT "(MEDIAN)": GOTO 350
340 PRINT
350 GOSUB 580
360 NEXT J
370 GOSUB 600
380 CLS: LP=3
390 PRIMT"FREQUENCY DISTRIBUTION"
400 PRINT " #             #TIMES"
410 C=1: LC=1: N=1
420 FOR J=1 TO I-1
430 IF A(J+1)=A(J) THEN C=C+1: GOTO 470
440 PRINT A(J),C: IF C>LC THEN LC=C: N=A(J)
450 GOSUB 580
460 C=1
470 NEXT J
480 GOSUB 600
490 CLS
500 PRINT "SUM OF ENTRIES=";T
510 PRINT "MEAN";T/(I-1)
520 PRINT "SUM OF SQUARES=";TS
530 V=(TS/(I-1))-(T/(I-1))^2
540 PRINT "VARIANCE";V
550 PRINT "STAN DEVIATION=";SQR(V)
560 GOSUB 600
510 GOTO 110
580 LP=LP+1: IF LP<>15 THEN 630
590 LP=1
600 PRINT "PRESS ANY KEY TO CONTINUE"
610 A$=INKEY$: IF AS="" THEN 610
620 CLS
630 RETURN