I am working on a table which has transaction records of a product in a store. Now I have to create a summary of transaction count by date. How can I do that?
Here's the code I am writing but it's not giving the desired output
transactions_by_date <- transaction_data %>%
group_by(transaction_data$DATE) %>%
summarise(count = n_distinct(transaction_data$DATE))
It's giving me a tibble of 364 x 2 of:
Date and total no. of distinct records in front of dates column like
2018-07-01 364
2018-07-02 364
2018-07-03 364
--and so on...
But I want total 364 records with date and no. of transactions made on that particular day