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

[Lens] Use different grouping order for non continuous data/charts #54589

Closed
timroes opened this issue Jan 13, 2020 · 4 comments
Closed

[Lens] Use different grouping order for non continuous data/charts #54589

timroes opened this issue Jan 13, 2020 · 4 comments
Labels
discuss enhancement New value added to drive a business result Feature:Lens Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects

Comments

@timroes
Copy link
Contributor

timroes commented Jan 13, 2020

If you currently have a terms split on the x-axis and then drag in a second field, you'll break down by that 2nd field and group "overall" instead of "per bucket" by default.

I think we should make this decision based on whether the data/chart on the x-axis is "continuous" or not. So I would suggest something like: as long as the type is bar chart and the x-axis is not a date field, we want to use "per bucket" grouping by default, and "overall" otherwise.

Reasoning: If you have non continuous data like strings in a bar chart, it's likely that the bars itself has nothing to do with each other, and if you break down you want to break down each bar individually. As an example, I ran very often into that, when e.g. splitting bars by country/city/airport and then want the top 5 whatever... I usually always want them per country/city/airport and not the top 5 overall. I think you only want the top 5 overall usually if the data you're drawing at the x-axis is continuous, why I would use above distinction as a separation for this decision.

I also feel it's a bit confusing or not very intuitive for non continuous data, because we let the user say: they want the top 3 cities on the x-axis, and break down by (in the following example) top 3 weathers, and they suddenly see potentially more then 3 bars on the x-axis:

screenshot-20200113-164051

@monfera @markov00 What are your feelings towards this?

@timroes timroes added Team:Visualizations Visualization editors, elastic-charts and infrastructure Feature:Lens labels Jan 13, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@github-actions github-actions bot added this to Long-term goals in Lens Jan 13, 2020
@markov00
Copy link
Member

markov00 commented Jan 16, 2020

@timroes I think this should be clarified in the UI with a better approach, than just with assumptions, hidden defaults modes.
Let me try to explain with few use cases:

  1. show me the top five airport cities and, for each of them, show me their respectively top 5 destinations for their flights. (on the edge case the visualization can have 5 * 5 different destinations)

  2. show me the top five airport cities and, for each of them, show me the counts of flights to the top 5 destination overall. (this will have the max of 5 different destinations)

For the 1. case i'm imagining the following UX:

  • I will drag the airport field to the x axis to split the data by the top airports
  • I will then drag destination into something that resamble a child relation of the airport field, that helps me to remember that I'm splitting each airport by their top 5 destination.

For the 2. case i'm imagining the following UX:

  • I will drag the airport field to the x axis to split the data by the top airports
  • I will then drag destination just below the airport field, (not child but sibling) that helps me to remember that I'm splitting the 5 overall destination.

I think that UX could be implemented providing some nice drop areas with a text that shows what will happen in a position or another:
Screenshot 2020-01-16 at 13 00 04

If the user just drop the field on the visualization itself, we can display an opaque overlay on the chart showing the options: drop as a child group/split or drop as an overall aggregation.

That's just an idea, we can also fix the Break down by field to accomodate the break down each single X value and break down all with an overall aggregation.

From a point of view of defaults:

  • with continuous data (x is time for example) the breakdown by default should be overall
  • with categorical data, the breakdown by default should be by category

@wylieconlon
Copy link
Contributor

I think this is a larger problem that needs to be broken down into smaller problems.

  1. It seems like we had the wrong default order for the Terms aggregration, but that's now been fixed in [Lens] Improve suggestions when dragging field for the second time #60687
  2. It is still possible to swap the order of the Terms aggregations when you have 2, and the results are sometimes confusing. I don't think we are tracking this in a nice way
  3. The UI doesn't represent the aggregation order, like what Marco is saying. I've proposed a different way of solving this than what Marco has mocked up: [Lens] XY configuration for aggregation order #62385

@flash1293 flash1293 added the enhancement New value added to drive a business result label Aug 6, 2020
@flash1293 flash1293 moved this from Long-term goals to 7.10 in Lens Sep 10, 2020
@flash1293 flash1293 moved this from 7.10 to Long-term goals in Lens Sep 14, 2020
@stratoula
Copy link
Contributor

I am closing this as we have separate issues for tracking the different problems described here

@markov00 markov00 added vis:suggestions Team Visualization: issue related to chart suggestions and removed vis:suggestions Team Visualization: issue related to chart suggestions labels Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discuss enhancement New value added to drive a business result Feature:Lens Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
No open projects
Lens
  
Long-term goals
Development

No branches or pull requests

7 participants