About SoloChart
The web charts referenced by the Philadelphia Region
SCCA Solo II Charts page are programmatically generated by a series
of small programs I've written. (You really don't think I was masochistic
enough to hand craft each of the charts did you? - Just masochistic enough
to write the programs that generate them ;)
PHLSoloResults
PHLSoloResults is a Java application that reads the race results of each
Philadelphia Region SCCA Solo II event (see http://www.autox4u.com/phillysolo.htm)
and reduces the information into raw comma separated value data (CSV) files.
This greatly simplifies subsequent processing. The CSV format is
defined to have the following ordered fields:
-
Car Number
-
Car Class/Category
-
Driver Name
-
Car Description
-
PAX Time
-
Actual Times (one or more)
CSV
CSV is a Java application that reads CSV files, manipulates it, and produces
another CSV file. CSV works irregardless of the nature of the values
being processed. The two options useful for producing the Solo II
charts are:
group
Groups all lines according to a specified column with a specified ordering.
In the standard category results, all lines are grouped according to column
2 (car class/category) with an ordering of SS, AS, BS, CS, DS, ES, FS,
GS, HS, ASP, BSP, CSP, DSP, ESP, AP, BP, CP, DP, EP, AM, BM, CM, DM, EM,
FM, ST1, L, and N.
sort
Sorts all lines according to a specified column 5. In the PAX results,
all lines are sorted according to column (PAX Time).
SoloChart
SoloChart is a Java application that reads CSV files in the format specified
above and produces the final HTML files. The HTML files make extensive
use of tables.
Generating the 1997 Holbert Memorial Charts
The following script file takes the 1997
Holbert Memorial results and produces the class/category chart and
CSV file, as well as the PAX chart. Though these Java applications
are run on my home Windows 95 PC, they can also be run on most other computers
(e.g., Unix) due to the portable nature of Java.
-
jview PHLSoloResults <txt\event8.txt
>temp8.csv
-
jview CSV group SS AS BS CS DS ES FS GS HS ASP BSP CSP
DSP ESP AP BP CP DP EP AM BM CM DM EM FM L N <temp8.csv >phl97\event8.csv
-
jview solochart "Event 8 - Holbert Memorial" "Sept 28, 1997
Camden, NJ" 34 70 <phl97\event8.csv >phl97\event8.html
-
jview CSV sort <temp8.csv >phl97\pax8.csv
-
jview solochart "Event 8 - Holbert Memorial" "Sept 28, 1997
Camden, NJ" 34 70 <phl97\pax8.csv >phl97\pax8.html
Step 1 produces the raw CSV file. Steps 2-3 produces the class/category
results. Steps 4-5 produces the PAX results. Here's the play-by-play:
-
jview is Microsoft's Java compiler (JavaSoft's
javac can be used as well) used to run PHLSoloResults which processes event8.txt
and generate temp8.csv.
-
temp8.csv is not grouped by car category (since the original event8.txt
are not). Therefore, temp8.csv is fed into CSV and is grouped according
to the car classes/categories seen to produce event8.csv.
-
SoloChart is fed some title information, the time range to be charted (34
- 70 seconds), and the previous event8.csv file. It produces the
event8.html file that you see.
-
To produce the PAX chart, temp8.csv (from step 1) is again passed through
CSV, except this time, it is sorted by PAX time, producing pax8.csv.
-
SoloChart is again called upon to produce pax8.html from pax8.csv.
Future Projects
Hopefully you have not been totally bored or lost in the tech talk.
Here are some other projects I (or you) might like to undertake sometime:
-
Chart non-PHL results. All one has to due is write a program
or script (e.g., AWK, Perl, etc.) to process some other region's results
and produce files in the CSV format described above. The CSV and
SoloChart programs above would not have to be modified at all!
-
Produce derived statistics. I've posted the CSV files on my
site hoping that someone will use them to produce interesting statistics.
Currently I merely report and graph the actual and PAX times.
-
Produce driver histories. Currently all results are event-based.
It would be nice to have page (or a section of a page) containing links
to all events a given driver raced in.