I want to use aggregate() to group my models of cars in my data.
I used this code to get an averages for one column. It gave me averages for all numerical columns.
aggregate(x, by = list(x$`Model Name`), FUN = mean)
Now, how do I edit this code to pick which columns I want to average and which columns I want to SUM?
This code averages everything by grouping them by 'Model Name'. I want some columns to use FUN=mean and some FUN=SUM
Actually, Can this be done with summarize() ?
Never mind, I got it using summarize(),