EasyManuals Logo

Radio Shack TRS-80 Model 100 User Manual

Radio Shack TRS-80 Model 100
210 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #112 background imageLoading...
Page #112 background image
r
..
850
DATA
300,
330,
315,
380
2000
GOTO
2000
Run this program.
You should see the following display:
450
400
350
300
250
200
150
.
0
4 8
12
16
20
24
28
You will have
to
press
IBREAKJ
to terminate execution
of
this program.
This graph depicts sales
as
a function
of
time, with the horizontal (X) axis
representing time
in
quarters
of
a year and the vertical (Y) axis representing sales
volume.
One advantage
of
displaying the data in graph form
is
that the pattern
of
sales
is
easier
to discern. In this case, for example, it
is
apparent that a long term upward trend in
sales exists. This was not so apparent from a tabular listing of the sales data.
Lines
58 - 748 The first part of the program remains unchanged which draws and
labels the axes.
Line
758 This begins a FOR/NEXT loop which reads the sales data from the Data
statements. There are six years
of
four quarters, so the total number
of
points will
be
24.
Line
769 The PSET statement
is
used to tum on cells corresponding to each sales
point. The axes
of
the graph (where
X=0
and Y = 136)
is
at graphic cell (33,54).
Horizontally, the quarters are spaced six cells apart. The X coordinate
of
quarter one
is therefore computed
as:
33
+ 1*6, = 39,
the second quarter
as:
33
+ 2*6 = 45,
and, in general, quarter X
as;
The computation
of
the vertical coordinate
is
a little more complicated. One reason for
this is that graphic cell vertical coordinates increase from the top to the bottom of the
display, whereas the graph itself assumes that values increase from bottom to top. The
horizontal axis corresponds to a value
of
136, which was carefully chosen
so
that the
labels line
up
with reasonable values (150, 200, etc.).
106

Other manuals for Radio Shack TRS-80 Model 100

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Radio Shack TRS-80 Model 100 and is the answer not in the manual?

Radio Shack TRS-80 Model 100 Specifications

General IconGeneral
BrandRadio Shack
ModelTRS-80 Model 100
CategoryDesktop
LanguageEnglish

Related product manuals