Grouping a dataframe in R by multiply columns and performing calculations on grouped data
I have a dataframe df
in R of sports teams, including a column Season
, Date
, and Goals
for every match, like so:
I have a dataframe df
in R of sports teams, including a column Season
, Date
, and Goals
for every match, like so: