Google
 

Trailing-Edge - PDP-10 Archives - decuslib20-04 - decus/20-0127/normal.for
There are 2 other files named normal.for in the archive. Click here to see a list.
00100	C   AUTHOR:  JOSEPH K. WILLIAMS, DEC, MAYNARD, MASS.
00200	C
00300		DIMENSION X(300)
00400	C
00500	C   INPUT RAW TEST SCORES
00600		DO 1 I=1,300
00700		WRITE(5,6)
00800		READ(5,7)X(I)
00900		IF(X(I).LE.0.0)GO TO 2
01000		SUM=SUM+1.0
01100		ISUM=ISUM+1
01200		TOT1=TOT1+X(I)
01300		TOT2=TOT2+(X(I))**2.0
01400	1	CONTINUE
01500	C
01600	C   CALCULATE SAMPLE MEAN
01700	2	AVG=TOT1/SUM
01800	C
01900	C   CALCULATE SAMPLE STANDARD DEVIATION
02000		STDEV=SQRT((TOT2-(TOT1**2/SUM))/SUM)
02100	C
02200	C   BEGIN SORT
02300		N1=ISUM-1
02400		DO 4 I=1,N1
02500		J=I+1
02600		DO 3 K=J,ISUM
02700		IF(X(I).GE.X(K))GO TO 3
02800		TEMP=X(I)
02900		X(I)=X(K)
03000		X(K)=TEMP
03100	3	CONTINUE
03200	4	CONTINUE
03300	C
03400	C   INPUT TOTAL POPULATION PARAMETERS
03500		WRITE(5,8)AVG,STDEV
03600		WRITE(5,9)
03700		READ(5,7)POAVG
03800		WRITE(5,10)
03900		READ(5,7)PODEV
04000	C
04100	C   PRINT REPORT ON TERMINAL
04200		WRITE (5,12)POAVG,PODEV
04300		DO 5 I=1,ISUM
04400		Z=(X(I)-AVG)/STDEV
04500		ADJVU=POAVG+Z*PODEV
04600		WRITE(5,11)X(I),ADJVU
04700	5	CONTINUE
04800		STOP'      END OF REPORT'
04900	C
05000	6	FORMAT(14H TEST SCORE ? ,$)
05100	7	FORMAT(F4.0)
05200	8	FORMAT(19H THIS SAMPLE HAS A ,F6.2,
05300		110H MEAN WITH/3H A ,F6.2,29H
05400		2 STANDARD DEVIATION. TO PRINT /
05500		339H THE NORMALIZED VALUES FOR THIS
05600		4 SAMPLE,)
05700	9	FORMAT(28H WHAT MEAN SHOULD BE USED ? ,$)
05800	10	FORMAT(27H+WHAT STANDARD DEVIATION ? ,$)
05900	11	FORMAT(1H 5XF4.0,5X,F6.3)
06000	12	FORMAT(1H1,3X,21H   POPULATION MEAN =
06100		1 F6.2/1H 3X,21HSTANDARD DEVIATION = F6.2/
06200		21H0,6X,3HRAW,3X,10HNORMALIZED/
06300		31H ,4X,6HSCORES,4X,6HSCORES/
06400		41H ,4X,6H------,2X,10H----------)
06500		END