NFL2007 | R Documentation |
Results of National Football League games (2007 season, including playoffs)
A data frame with 267 observations on the following 7 variables.
date on which game was played
visiting team
score for visiting team
home team
score for home team
‘betting line’
'over/under' line (for combined score of both teams)
data(NFL2007)
NFL <- NFL2007
NFL$dscore <- NFL$homeScore - NFL$visitorScore
w <- which(NFL$dscore > 0)
NFL$winner <- NFL$visitor; NFL$winner[w] <- NFL$home[w]
NFL$loser <- NFL$home; NFL$loser[w] <- NFL$visitor[w]
# did the home team win?
NFL$homeTeamWon <- NFL$dscore > 0
table(NFL$homeTeamWon)
table(NFL$dscore > NFL$line)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.