home *** CD-ROM | disk | FTP | other *** search
- F I G
-
- "FOG Index Generator"
-
- by Lee David Rimar
- 1988, No Rights Reserved
-
-
- -- PURPOSE --
-
- FIG.COM analyzes ASCII text files. It generates some statistics
- which pertain to "readability."
-
- FIG also offers comments and suggestions on ways to make the text
- more readable. For example, if the sentences tend to be too long,
- FIG might display this:
-
- Average sentence length: 22 words.
- -> Sentences may be too wordy.
-
- Among the other stats is a FOG index. This number roughly matches
- the reading-level needed to comprehend the text. For example, a FOG
- index of 8 means the text should be understandable by an 8th grader.
-
- When writing for the general public, a FOG index of 8 to 10 is
- desirable. If it's much higher, the writing may seem overbearing.
- If it's much lower, the writing seem choppy.
-
- By paying attention to FIG's comments and suggestions, you can make
- your text easier to for others to read.
-
-
- -- ORIGINS --
-
- This is an extensive re-work of WRITER.BAS, which originally appeared
- in CODEWORKS magazine.
-
- FIG.BAS was tested and debugged with BASIC-80 (MBASIC v5.21). The
- version distributed in this ARChive should also run correctly under
- any of the 16-bit BASICs which have their roots in Microsoft:
- BASICA, PCBASIC, GWBASIC, et al.
-
-
- -- HOW TO USE IT --
-
- At your system prompt, enter: BASIC FIG
-
- BASIC (or GWBASIC, or whatever Basic you use) will load FIG. FIG
- will then prompt for a filename. It will take anywhere from 5 to
- 30 seconds to analyze the file.
-
- FIG reads only "normal" ASCII files. Lines must be shorter than 128
- characters, and should be terminated with standard carriage return-
- line feed combinations.
-
- Those limitations exclude WordStar document files, but these may be
- processed with any of several utility programs available to convert
- them to ASCII.
-
- -- HOW FIG READS FILES --
-
- FIG usually needs at least 100 words of text to generate accurate
- statistics. Up to a point, more text means more reliable results.
- To balance accuracy against extra analysis time, FIG "samples" long
- files instead of reading them completely.
-
- On short files (under 400 words) FIG reads and analyzes the whole
- thing. But on longer files, FIG stops reading at the end of the
- first sentence it finds past the 400-word mark. Normally this is a
- large enough sample to give reliable results.
-
- If FIG can't find the end of a sentence after 400 words, it will just
- stop reading on the 500th word. Also, FIG will never read more than
- the first 100 text lines of a file.
-
-
- -- OTHER LIMITATIONS --
-
- FIG doesn't "understand" what it reads; it only analyzes some of the
- "mechanics" of writing. It might not be reliable analyzing technical
- writing or material with a specialized vocabulary.
-
- FIG works best on "blocks" of text, paragraph or line oriented.
- Using it on files with many headings (like this document) or columns
- will not give accurate results.
-
- FIG doesn't generate a word-frequency list or count unique words.
- That was a feature in WRITER.BAS (of which FIG is an offshoot), and I
- had originally planned to include it. But it slowed the program down
- so much that I left it out. I don't consider this a great loss; most
- spelling checkers generate that kind of information.
-
- FIG is stupid about hyphens; it treats a hyphenated word as two
- words. This will throw off the word count. But unless you use a LOT
- of hyphens, it won't affect the other statistics appreciably.
-
-
- -- LEGAL? NOTICE --
-
- This program is "public domain" in the full sense of the word. So
- many people have contributed to this work (see CREDITS below) that
- all I can take credit for is the current structure and details of the
- code.
-
- Use it at home, at work, give it to your friends, whatever. You can
- even (try to) sell it, but I doubt you'll find any buyers. Modify it
- it if you like -- but at least be nice and pass your changes on; back
- into the public domain.
-
- The flip side of the coin: No warranties are expressed or implied on
- the suitability of this program for any purpose. I will not be held
- responsible for anything related to it, period. You're on your own.
-
-
- -- CLOSING COMMENTS --
-
- I can be contacted on either of the following bulletin boards:
-
- Detroit Area Kaypro User's Group RBBS: (313) 772-0522
- Tony's Corner QBBS (FidoNet 120/13): (313) 754-1131
-
- Comments, questions, or other notes relating to this program are
- always welcome; as are modifications, enhancements, gifts of food
- and/or money, and/or marriage proposals.
-
-
-
- Lee David Rimar 29 April, 1988
-
-
-
- -eof-