The dplyr summarize function takes a data frame as its first argument, followed by "Name-value pairs of summary functions."
Have a look at the docs, there are a few examples in there of how to make use of summarize.
On Screenshots - This is a good example of when a screenshot isn't as good as a reprex or just copy-pasting your error message.