SPECIFICATION OF ASCII FILE FORMAT - RELEASE 3.11                   PAGE 1 OF 7

The data to be "imported" must be in ASCII (say "askee") format, because this
is a universal format which can be understood by most communications, spread-
sheet and database programs.  ASCII is a standard which describes the bit pat-
terns used for computer storage of individual letters, digits, puncutation and
other special characters.  For example the capital letter "A" has the bit pat-
tern 01000001.  Most personal computers can recognize ASCII.  Textual informa-
tion, such as what you are reading now, is usually stored in ASCII format.

Numbers must be in a binary format before they can be used in calculations by a
computer.  The Stock Charting System stores volume, prices, dates and other in-
formation in a binary format.  Therefore, numbers in ASCII must be "translated"
to binary before they are useful for calculations.

On the ASCII input file, the lines can be in any order.  The program looks for
and processes only those individual lines which contain valid data. Lines which
contain column headings, explanatory information, advertising, communications
protocol and other things are ignored.  Normally all of the information for one
security will always be on one line.  The data items for each security can be
in any order; and items not wanted, such as dates, can be skipped.  If you use
CompuServe or another service that splits lines, see page 7 of these screens.  

SPECIFICATION OF ASCII FILE FORMAT FOR UPDATING CURRENT PRICES      PAGE 2 OF 7

Normally, the first data item the program looks for on each line is a valid
stock symbol.  If this symbol does not exist in the catalog, or if there is no
corresponding price history file, the whole line is ignored.  Otherwise, the
program scans that same individual line from left to right and looks for valid
data items.  If the required data items are found, they are converted to binary
format. The number values are checked for "reasonableness" and for proper rela-
tionship, for example high or ask >= closing price >= low or bid.  ( >= means
"greater than or equal to".)  Any error will cause that line to be discarded. 

Data items must be separated by blank spaces or other non-numeric characters.
Either fractional or decimal values are acceptable. Fractions must be separated
from their corresponding whole numbers by one and only one blank space.

The program will ignore characters such as * to indicate ex-dividend.  It will
also ignore any quote marks or commas that may be used to separate data items.
Thus, it will accept data in the CSV, or comma-separated value, format which is
used by some database programs.  It is the responsibility of the user, in the
process of using the external communications or other program of his or her
choice, to make sure the required data items are available.


SPECIFICATION OF ASCII FILE FORMAT FOR UPDATING CURRENT PRICES      PAGE 3 OF 7

Here are some examples of acceptable data, in order by stock symbol, high, low,
close and volume:

         IBM   *120        109 3/4    110 1/2   110375   (* is ignored)
         "SGAT",15.25,14,14.875,56259   (CSV format)
         fg   31.125 29 30.5 4075   (lowercase stock symbol is OK)

The prompt you were responding to before these Help screens is necessary to
specify the sequence in which data items appear in the file you are "importing"
into the Stock Charting System.  This sequence may vary, depending on what
source the data comes from.  The required data items must be in the same order
on each line they appear on.

Each required data item is identified by a letter of the alphabet, such as
A for ask or high, B for bid or low, etc.  The sequence in which data items
appear in the input is specified by typing those letters in a corresponding
sequence, for example TABCV for ticker-high-low-close-volume.  If you don't
know the sequence, you can find out from the documentation for the program that
created the file, or by visual inspection after displaying the file on the
screen or printer.  Usually the program that created the file also displays it. 

SPECIFICATION OF ASCII FILE FORMAT FOR UPDATING CURRENT PRICES      PAGE 4 OF 7

To skip over a data item you don't want to use, type the letter "R" if it is a
stock price (ask/bid/last/open/etc.); otherwise type the letter "S". In general
you can use "S" to skip any data item, UNLESS it may contain a number with a
fractional value such as 2 11/16.  "S" skips anything delimited by spaces or
double quotes, so it won't work on fractions.  That's why you have to use "R"
to consistently skip over numeric values that may or may not contain fractions.
Either "R" or "S" will work with whole numbers and decimal values.

For example when receiving current quotes from Dow Jones Information Services,
the data items are in order by ticker symbol, bid/close, ask/open, high, low,
last, volume.  The "bid/close" is the previous day's closing price and "ask/
open" is today's opening price, which the program does not use.  The current
day's closing price is in the column labelled "last".  Therefore, you type the
letters TPRABCV to specify the data item sequence.  You MUST specify where the
stock symbol is; the program does NOT assume it is the first item on each line. 

Use S instead of R to skip any contiguous field such as the time of day.        

Use V for volume in hundreds (the normal case).  Otherwise use U.  Which one
to use can only be determined by inspecting the data.

SPECIFICATION OF ASCII FILE FORMAT FOR UPDATING CURRENT PRICES      PAGE 5 OF 7

Not all of the aforementioned data items must be present.  The program can use
the ticker symbol, the current volume, high, low and close, and the previous
close.  However the only items that absolutely must be available on each line
are the ticker symbol and either the current closing price (or net asset value)
or the ask and bid prices.  If the ask and bid prices are present, but not the
closing price, the closing price is set to the bid price.  If only the closing
price is present, the high and low are set equal to the close.

Data items that appear in the input data after the last item you want do not
have to be specified.  For example, assume you want to pick up only the current
closing price, and that each input line contains the time, ticker symbol, pre-
vious close, current high-low-close and volume.  In this case you would specify
STRRRC.  The volume would be ignored.  Remember in this version of the program
you MUST specify the ticker symbol, and it need not be the first item in the
line.  (In Release 2.54 and earlier versions, you didn't have to specify T for
the ticker symbol - the program always assumed it was the first item on each
line.)




SPECIFICATION OF ASCII FILE FORMAT FOR UPDATING CURRENT PRICES      PAGE 6 OF 7

After the "translation" process is finished, the data is shown on the screen
and you can inspect it.  If you didn't get any data at all, or you got only one
or two lines, the most likely cause is the data items are not in the same order
that you specified.  You should visually inspect both the incoming ASCII data
and the resulting Stock Charting System data to make sure everything is reason-
able and hopefully correct.  Glitches on the telephone line (when receiving
data through a modem), or garbage in the data, could cause information to be
lost in the translation process.  If you have persistent problems, there is a
slight possibility that you might have to use a word processor or text editor
to edit the ASCII data file to get rid of garbage, before "importing" it into
the Stock Charting System.

WARNING: The Import function does not actually update the price history files.
You must invoke the UPDATE function to do this.  This process is not automatic,
to give you an opportunity to inspect the data first.






SPECIFICATION OF ASCII FILE FORMAT FOR UPDATING CURRENT PRICES      PAGE 7 OF 7

If you use CompuServe or any other database service which splits the informa-
tion for each security among two or more lines, you have a special problem,
which this program can handle.  Use the letter G to skip to the next line in
the ASCII file.  For example, suppose your input data for each stock looks like
this:

STOCK IBM 11:54:07 EST

 DATE       CLOSE      OPEN      ASK       BID
                                HIGH       LOW      LAST      VOL (100s)

2/6/90      109 1/8    109     109 7/8   107 3/4   109 3/8     13456

To "import" this data, specify the format STGGGSRRABCV.  The first "S" skips
over the word STOCK (otherwise the program will think that is a ticker symbol).           
The T picks up the real ticker, IBM.  GGG skips 3 lines, ignoring the time and
EST (you don't have to explicitly skip empty lines).  The second S skips the
date and RR skips the previous close and today's open.  You might consider
writing the format down and sticking it to your monitor once it is working.
