I have a dataset of observations by day for several months and need to find the average of the observations for each day. The data is from a tab delimited text file with the following column names: Day, Date, Views, Engagement, Sales. I'm trying to find the average Views, Engage., and Sales for all 7 days of the week. In SAS I would have just used proc tabulate with Day as the class and Views, Engagements, and Sales as the variables but I'm unsure of how to translate this into R code.
Monday 21JUL03 7206 32 $6.73
Tuesday 22JUL03 9333 51 $4.99
Wednesday 23JUL03 8321 61 $8.87
Thursday 24JUL03 8378 35 $3.69
Friday 25JUL03 12202 45 $4.34
Saturday 26JUL03 6161 34 $3.12
Sunday 27JUL03 9115 29 $2.77
Monday 28JUL03 17112 51 $10.36
Tuesday 29JUL03 12690 51 $10.24
Wednesday 30JUL03 10822 30 $3.96
Thursday 31JUL03 10395 41 $5.45
Friday 01AUG03 6979 31 $2.95
Saturday 02AUG03 3810 19 $1.78
Sunday 03AUG03 4554 30 $5.71