Dec 212017
A dbase routine to plot a bar chart from a database file. | |||
---|---|---|---|
File Name | File Size | Zip Size | Zip Type |
MKT_PRC.DBF | 1522 | 415 | deflated |
MKT_PRC.MDX | 6144 | 2066 | deflated |
PLOTME.PRG | 4067 | 1577 | deflated |
README.TXT | 1352 | 685 | deflated |
Download File PLOTME.ZIP Here
Contents of the README.TXT file
This is a program to plot values in a dbf in bar-graph form. The example
.dbf included with this program (mkt_prc.dbf) contains the fields:
acct, date and mkt_pr.
In this database, the the market price is entered at the end of each month
for each investment account. The enclosed .dbf contains only one account,
FIDELITY MAGELLAN MUTUAL FUND.
The plotting program always uses the far right value of the x-axis as the
end of last month. The .dbf is indexed on the acct+DTOS(date). The program
finds the last record (chronologically) and starts plotting price
right-to- left backwards until either the first price is reached or the
minimum value of the horizontal (date) axis is reached.
The program will also plot negative values. This is because I also compute
the 12-month Modified Internal Rate of Return for each investment using a
spreadsheet for each month and also plot this value and then enter these
values into another .dbf. I thus have the top halve of the screen with
%-Return vs Date and the bottom half with Price vs Date. This is a whole
other subject though.
The program will work with any .dbf that has the fields of date and value
to plot. It can be modified for your particular database. The calculations
for value to screen conversion is subtle but you can follow the code.
Enjoy....Peare
.dbf included with this program (mkt_prc.dbf) contains the fields:
acct, date and mkt_pr.
In this database, the the market price is entered at the end of each month
for each investment account. The enclosed .dbf contains only one account,
FIDELITY MAGELLAN MUTUAL FUND.
The plotting program always uses the far right value of the x-axis as the
end of last month. The .dbf is indexed on the acct+DTOS(date). The program
finds the last record (chronologically) and starts plotting price
right-to- left backwards until either the first price is reached or the
minimum value of the horizontal (date) axis is reached.
The program will also plot negative values. This is because I also compute
the 12-month Modified Internal Rate of Return for each investment using a
spreadsheet for each month and also plot this value and then enter these
values into another .dbf. I thus have the top halve of the screen with
%-Return vs Date and the bottom half with Price vs Date. This is a whole
other subject though.
The program will work with any .dbf that has the fields of date and value
to plot. It can be modified for your particular database. The calculations
for value to screen conversion is subtle but you can follow the code.
Enjoy....Peare
December 21, 2017
Add comments