Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Idea] Group by hour of the week #258

Closed
fedegl opened this issue Jan 21, 2022 · 1 comment
Closed

[Idea] Group by hour of the week #258

fedegl opened this issue Jan 21, 2022 · 1 comment

Comments

@fedegl
Copy link

fedegl commented Jan 21, 2022

Hi, here is an idea for a new type of grouping.

The grouping options right now include by_hour_of_day or by_day_of_week but there isn't a by_hour_of_week.

This grouping would be useful to create a Heatmap of a visits by hour of the week, similar to the one Google Analytics has.

Screen Shot 2022-01-21 at 9 26 16

Thanks for the awesome suite of libraries for Analytics!

@ankane
Copy link
Owner

ankane commented Jan 28, 2022

Hey @fedegl, you can do:

Visit.group_by_day_of_week(:started_at).group_by_hour_of_day(:started_at).count

@ankane ankane closed this as completed Feb 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants