home *** CD-ROM | disk | FTP | other *** search
/ Frostbyte's 1980s DOS Shareware Collection / floppyshareware.zip / floppyshareware / USCX / TURBO-11.ZIP / TESTSIGF.PAS < prev    next >
Pascal/Delphi Source File  |  1985-05-17  |  2KB  |  58 lines

  1. (*--------------------------------------------------------------------------*)
  2. (*                 TestSigF --- Test F significance routine                 *)
  3. (*--------------------------------------------------------------------------*)
  4.  
  5. PROGRAM TestSigF;
  6.  
  7. (*--------------------------------------------------------------------------*)
  8. (*                                                                          *)
  9. (*   Program:  TestSigF                                                     *)
  10. (*                                                                          *)
  11. (*   Purpose:  Demonstrate F-significance routine in PIBSIGS.LBR            *)
  12. (*                                                                          *)
  13. (*   Usage:    This program prompts for an F-value and corresponding        *)
  14. (*             numerator and denominator degrees of freedom.  It computes   *)
  15. (*             and prints the significance level for the gievn F value.     *)
  16. (*                                                                          *)
  17. (*             To stop the program, enter a t value of -99.                 *)
  18. (*                                                                          *)
  19. (*   Calls:    SigF                                                         *)
  20. (*                                                                          *)
  21. (*--------------------------------------------------------------------------*)
  22.  
  23. VAR
  24.    F:    REAL;
  25.    Dfh:  REAL;
  26.    Dfe:  REAL;
  27.    P:    REAL;
  28.    Done: BOOLEAN;
  29.  
  30. (*$I SIGCONST.PAS *)
  31. (*$I LOGTEN.PAS   *)
  32. (*$I POWTEN.PAS   *)
  33. (*$I ALGAMA.PAS   *)
  34. (*$I CDBETA.PAS   *)
  35. (*$I SIGF.PAS     *)
  36.  
  37. BEGIN (* TestSigF *)
  38.  
  39.    Done := FALSE;
  40.    ClrScr;
  41.  
  42.    REPEAT
  43.  
  44.       WRITE('Enter F-value, numerator DF, and denominator DF (-99 to stop): ');
  45.       READLN( F, Dfh, Dfe );
  46.  
  47.       IF ( F <> -99.0 ) THEN
  48.          BEGIN
  49.             P     := SigF( F, Dfh, Dfe );
  50.             WRITELN('Significance value = ',P:8:5);
  51.          END
  52.       ELSE
  53.          Done := TRUE;
  54.  
  55.    UNTIL Done;
  56.  
  57.  
  58. END   (* TestSigF *).