Results File Format

A List of Results

The Football Statistics Applet generates all of its statistics from a simple list of results. The results file (usually given a .rlt extension) is a plain text file that consists of a list of results, one per line. An extract from a typical results file is shown below:

      13082005|Aston Villa|2|Bolton Wanderers|2|33263
      13082005|Everton|0|Manchester United|2|38610
      13082005|Fulham|0|Birmingham City|0|16550
      13082005|Manchester City|0|West Bromwich Albion|0|42983

Each result is made up of a number of fields separated by the | character (ASCII code 124). The first field is the date (in DDMMYYYY format with no separators). The second field is the name of the home team, the third field is the number of goals scored by the home team, the fourth field is the name of the away team, the fifth field is the away team's score and the final field is the attendance for the match.

It is not necessary to include attendance data in the results file, in which case a typical entry would be as follows:

      13082005|Aston Villa|2|Bolton Wanderers|2

Note that there are no separators at the beginning or the end of the line and there are no spaces except where these occur within team names.

Each occurrence of a particular team name must be entered identically (including capitalisation and spaces). "QPR" for example is not the same as "Queens Park Rangers", and "Liverpool" is not the same as "LIVERPOOL". If team's names are entered differently they will be treated as different teams and as a result the statistics will be incorrect.

It is important to note that, for version 2.0.3 and earlier, all results must be listed in chronological order. The earliest result must be at the top of the file and the latest at the bottom, with results from the same date grouped together. If the results are not arranged like this, some of the statistics generated by the applet will be wrong (version 3.0 removes this restriction).

Incorporating Promotion/Play-Offs/Cup Qualification/Relegation Zones

The above information is all that is required in order to create a working results file. However, the Football Statistics Applet includes a feature that can highlight important positions in the league table. This can be used to show, among other things, which teams are in the relegation zone, or which teams will qualify for promotion or promotion play-offs. This highlighting is achieved by adding PRIZE and RELEGATION entries to the top of the results file. An example of these entries, for the 2005/06 English Premiership season, is shown below:

      PRIZE|1|1|Champions
      PRIZE|2|2|UEFA CL Group Stage
      PRIZE|3|4|UEFA CL Qualifying
      PRIZE|5|7|UEFA Cup
      RELEGATION|18|20|Relegation

Each entry represents one zone in the table and the two numeric fields represent the start and end positon for that zone. These five lines appear at the top of the full results file, before any of the results.

Configuring League Rules

The applet defaults to using three points for a win and one for a draw. This can be over-ridden by adding the following entry to the top of a results file. The first number is points for a win, the second is points for a draw.

      RULES|2|1

Split-Table Leagues

FSA defaults to using a standard league format, but it also supports the structure used by the Scottish Premier League and Northern Ireland's IFA Premiership. These leagues split into two sections (top 6 and bottom 6 in a 12-team league) towards the end of the season. To achieve this, you need to inform the software at what point the split occurs. You do this by adding another value to the rules tag that specifies how many matches are played by each team before the split. For example, the SPL would use the following:

      RULES|3|1|33

Awarding and Deducting Points

Occasionally a team is deducted points for some infringement of the rules and their opponents may possibly be awarded points. To include this information, add an AWARDED or DEDUCTED entry at the end of your results file as shown below. There are no dates for these entries. The first field identifies the entry as a points modification, the second field is the name of the affected team and the third field is the number of points awarded or deducted:

      DEDUCTED|Doncaster Rovers|2
      AWARDED|Woking|2

Comments

To make the results files easier to work with, you can add comments to the files. Comments are ignored by the applet. A comment is any line that begins with a hash character ('#'). Here is an example of a comment:

      # This is a comment.