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

Updated date range selection workflow #9727

Closed
clarkus opened this issue May 10, 2022 · 4 comments · Fixed by #10462 or #10688
Closed

Updated date range selection workflow #9727

clarkus opened this issue May 10, 2022 · 4 comments · Fixed by #10462 or #10688
Labels
enhancement New feature or request feature/lemon-ui feature/saved-insights Feature Tag: Saved Insights

Comments

@clarkus
Copy link
Contributor

clarkus commented May 10, 2022

Is your feature request related to a problem?

Selecting a date range in PostHog can be pretty tedious depending on what you're trying to accomplish. Select a starting date for a fixed time range requires three clicks / actions just to pick the first range parameter. Our list of preset rolling time ranges use days as the most common time unit, but research shows that users use a broader range of units.

Describe the solution you'd like

Prioritize selecting rolling / relative date ranges using a list of preset values. Reduce the number of options and provide a semi-custom rolling range via a numeric input and a time units. The core change here is to provide a semi-custom rolling time range option. These are always relative to the current date and are formatted as a numeric value and a time unit option. For example, the last [3] [days], the last [1] [quarter], the last [18] [weeks]. A custom option would reduce the need for specific presets. We could also increase user confidence if we translated relative ranges to actual time frames using tooltips.

Group 8966

Relative dates are represented as relative ranges in the summary state for the picker. Likewise, fixed / absolute range are more specific and show the actual range selected.
relative date summary
absolute date summary

Separate selecting a fixed / absolute range and provide reasonable defaults to reduce the number of actions it takes to submit a value. When selecting a custom fixed range, ditch the start and end date inputs and instead directly show the calendar immediately. A user would just need to select a start date to have a valid time range if the end date defaults to the current date.

Frame 8390

Changes to consider based on the research @marcushyett-ph did for https://github.com/PostHog/product-internal/pull/305

  1. Change the default rolling time range to 30 days for insights
  2. Automatically adjust time grouping units to the range selected. For example if you select the last 24 hours, today, yesterday, it doesn't make sense to group by any unit larger than a day. Hours would be the most approachable unit for this scenario.
  3. When selecting a fixed time range, disallow selection beyond the current date. It doesn't make sense to look at future dates in this scenario. We don't have data for the future as we don't do predictions. Our default end date for a custom time range should be the current date.
  4. When selecting fixed ranges, reduce the number of clicks / actions it takes to get to the calendar interface. Right now this takes three clicks just to pick a starting date. We also make users select an end date when we could have a reasonable default of the current date here.
  5. Add a quarterly option to the relative range picker
  6. Make it more obvious when a fixed range is applied to an insight.
  7. Consider expanding our preferences / project settings for time. For example, starting the week on Monday instead of Sunday, time value formatting (12 versus 24 hour clocks), timezones, etc.

Additional context

Thank you for your feature request – we love each and every one!

@clarkus clarkus added enhancement New feature or request feature/saved-insights Feature Tag: Saved Insights feature/lemon-ui labels May 10, 2022
@clarkus
Copy link
Contributor Author

clarkus commented May 10, 2022

Related but somewhat separate are time ranges for dashboards. Dashboards can override an insight's time range temporarily. The same considerations for picking a time range could apply to the dashboards feature.

@joethreepwood
Copy link
Contributor

This looks like it addresses my feedback perfectly - thanks Chris!

@marcushyett-ph
Copy link
Contributor

This is super-solid, thanks @clarkus!

@kappa90
Copy link
Contributor

kappa90 commented Jul 4, 2022

Incorrectly closed after #10462, which is meant to run as an experiment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request feature/lemon-ui feature/saved-insights Feature Tag: Saved Insights
Projects
None yet
4 participants