Skip to content

Extended RLT Data File Format

dwdyer edited this page Apr 13, 2013 · 4 revisions

The RLT data file format for football results is specified by the Football Statistics Applet (FSA). Anorak supports all data files accepted by FSA (though some options are ignored). Additionally, Anorak extends the format in a number of ways, principally by supporting the inclusion of goal-scorer information. This page describes the extended RLT format.

RLT Directives and Metadata Records

RLT is an ASCII text format that consists of a series of pipe-delimited records, one per line.

Include Directive

Include the data from another RLT file.

INCLUDE|path/to/results.rlt

Rules Directive

The RULES record type is used to over-ride the default league rules. The first two fields specify the number of points awarded for a win and the number of points for a draw. If the rules are not specified, Anorak defaults to 3 points for a win and 1 for a draw.

RULES|2|1

The optional third field specifies the number of matches played by each team before the league splits in half. This is used to implement the league format favoured by the Scottish Premier League and Northern Ireland’s IFA Premiership. It should be omitted or set to zero for sane leagues. For the SPL it would be set to 33 (each of the 12 teams plays each other three times, the league then splits into a top 6 and a bottom 6 and the teams in those two sections play each other once more for a total of 38 fixtures per club).

RULES|3|1|33

Points Adjustments

Teams can be awarded or deducted points to adjust the tally that they have earned through their results. Most typically used when a team has been docked points by the league for some infringement of the rules.

AWARDED|Woking|2
DEDUCTED|Doncaster Rovers|2

Mini-Leagues

Anorak supports the generation of league tables for “leagues within leagues”. For example, you could create a mini-league table for the London clubs in the English Premier League that includes only the results for matches between two London teams. The first field is the name of the mini-league, the remaining fields are the names of the member teams.

MINILEAGUE|London|Arsenal|Chelsea|Fulham|Tottenham Hotspur|West Ham United

Comments

Comments begin with a hash character and continue until the end of the line.

# This is a comment.

Results Records

Without Goal-Scorer Information

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 and the fifth field is the away team’s score.

15082009|Aston Villa|0|Wigan Athletic|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 teams’ names are entered differently they will be treated as different teams and as a result the statistics will be incorrect.

With Goal-Scorer Information

15082009|Aston Villa|0|Wigan Athletic|2[Hugo Rodallega31,Jason Koumas56]

If goal-scorer information is being tracked it should be entered in square brackets immediately after a team’s score (there are no spaces and no additional pipe separators). A goal-scorer entry consists of the player’s name and the minute of the match in which they scored (1-90). First-half injury time is always the 45th minute, regardless of how many minutes are played, and second-half injury time is always the 90th minute. Multiple goal-scorers should be separated by commas. There should be no spaces between goal-scorers or between player names and minutes. If a player scores more than one goal they must be entered more than once.

Penalties and Own Goals

Penalties are indicated by appending a lower case ‘p’ immediately after the minute the goal was scored. Likewise, own goals are indicated by a lower case “o”.

29082009|Manchester United|2[Wayne Rooney59p,Abou Diaby64o]|Arsenal|1[Andrei Arshavin40]