Measure vs. Measure Scatterplots (3.28+)

As of version 3.28, you can now plot measure vs. measure scatterplots. This can be done by hiding the dimension(s) in the data table from the visualization.

For example, say you have this data table:

7d6fcd55231a18dd332c99bd9f81b0c5192f9a8e.png

In order to chart Orders Count vs. Order Items Total Sale Price, you will want to hide Users Age from the visualization by selecting Hide from Visualization from that column’s gear dropdown:

fbecddd2515ed3b75d334069c0222b5870c37047.png

After selecting scatter from the chart icon options, you should see a chart like this!

fd6283baf0445b610980d1bfa6f9099c25a6db7d.png

7 80 10.2K
80 REPLIES 80

@rachel_johnson I am also still having the same issues depicted above. I’ve chatted in to support and provided simply 2 measures and 1 dimension and asked them to create what I’m requesting. They were unable to and stated it isn’t possible to do what I’m asking. Pivoting does not solve my issue - it simply creates what Milan is showing above.

@Milan_Veverka @dan_geneczko This feature is not currently available but I will definitely go ahead and pass on some feedback to our product team.

Thanks @adina_katz. Maybe a custom viz? Anyone? 🙂

Hey guys,

Adding onto the requests here - when viewing a measure x measure pivoted by dimension, it would be great if we were able to show the labels for a dimension without having to hover over each circle. Is this possible in any way / in the works?

Thanks for your feedback, Brandyn! I’ve passed it along to our product team 🙂

chasec
New Member

The custom viz from vega-lite supports this feature (and much more): https://github.com/groodlooker/vega-lite

2 posts were split to a new topic: Tooltip from hidden field in Visualizations

A post was split to a new topic: Vega-lite not working

Hi, I have a hack that might help here. But please note the code is a bit ugly… Here is what I think you are trying to get to, measure by measure pivoted on a dimension.

Basically the problem is that you need to plot a measure on a dimension in a scatter graph if you are pivoting. So this dataset I am using here has a grouping, distance and a duration for each id. I want to plot distance by duration pivoted on grouping.

The solution requires me simply to plot distance (as a dimension) by duration (as a measure, sum is fine). However when doing this, we run into the problem that the distance could have duplications. To get around this, I have a new dimension called distance_for_scatter, where I simply add 0.0000001*row_number which will guarantee that the distances will ALWAYS be unique. (obviously add enough zeros!). Then you can change the value_format_name to something less horrific like decimal_2, and it plots nicely!

dimension: distance_for_scatter {
type: number
sql: ${distance} + (0.000001 * ${row_number}) ;;
value_format_name: decimal_2
html: {{rendered_value}} km ;;
}

If you don’t have a row_number dimension, you can change the sql_table_name to a derived table with something like:
SELECT *, ROW_NUMBER() OVER() as row_number FROM tablename
and then have row_number as a dimension, type number.

dimension: row_number {
type: number
sql: ${TABLE}.row_number ;;
}

Oh and change the minimum Y value to 0.00001

Mais voila 🙂

Interesting solution but as you say - grim. We are still waiting since '15 for a default viz option for the dimensional field to be rendered as a colour on a measure-by-measure scatter plot. Is there an opposition at Looker to this? It’s common in statistical programming language packages ® to visualise data like this - think ggplot2.

I get this request from users very often - esp. from employees who previously used Tableau, as it was possible by default there. It’s a shame, because it is a beautiful way to visualise data (that is subjective of course).

4 years and this feature is still not there - extremely disappointed! This is so easy to do with any other tool (e.g. Tableau, R)!

+1 would really like to have this feature. Users keep downloading data and using excel instead and I’d like to keep them in Looker instead.

all the +1s. Two things we shoulds have in 2020

  1. a space station on the moon
  2. a scatter plot in Looker that actually works

Looker moonbase is coming soon, probably Q4 but don’t quote me on it. Yes, it will be purple.

Re: scatter plots, I admit that I have lost the plot of this thread a little bit. It’s 53 posts strong and stretches back to 2015, with Looker 3.28 😱 . I’m confident that we have made lots of improvements in that time, and there is the ability to do measure vs. measure scatterplots, so I’d like to baseline set to make sure I’m making the right recommendations to Product.

Is this:

the ask that you are all after, @Abhijit_Roy, @Ben_White, and @Katrina_Palen? As much context on what exactly you’d like to be able to do would be super helpful.

The issue being raised is that when displaying a measure x measure scatter plot, there is still no option to colour the data points by a dimension.

Being able to interpret the result this way is very useful, as it may be that one group (home owner / renter) is dominating the healthy top right area, and another the less healthy bottom left. This shows an example:

https://images.app.goo.gl/yvsrQynqqVLSJoS26

This is such a basic requirement for analysis, it would be great if this could be solved soon @izzymiller 🙏

I didn’t quite get the notification on your @ , apologies for not responding sooner, but yes, essentially the image shared by @Jamie_Matlock is simply the spec I’m looking for, nothing more than that (for now 🙂 )

just joined looker community to add my +1 ??‍♀️

….Just found a way to do this using the VEGA customization scatter. It’s not perfect though because it still won’t let me pivot - just lets me add more dimensions which means I have to pull in rows that I don’t want: 

cb9d7c81-1d05-487c-868c-1d062169ffee.png

+1 to this! It’s important to be able to group points by colour or shape on a measure by measure scatterplot.

To clarify the ask, this is what we’re after https://www.youtube.com/watch?v=DetQavLqfdg 🙂

+1 @izzymiller , Hows this one coming around ? I (and probably others) have so much to show via scatterplots, but are unable to show it due to the lack of Dimension application. 

setting up a measure v measure scatterplot is cool and all, but useless as of now since I cant show which dimensional value each plotpoint represents. 

I’m also very curious about this. 
 

Measure x measure scatter with dimensions is shown in Looker’s documentation here

It’s the first image in the Grid Layout section:

3553ac88-876e-4745-98da-4b595e462cc6.png

 
@izzymiller could you share how this was built? Thanks!

Hi @AA_Sacco, one way I found to make this work is to have x-axis as a dimension as indicated in the doc

7538f3cd-06cf-4142-b69f-1b09b543dd4c.png

This is what the data section looks like for the chart in your reply^^^. It is in the same doc. 

+1 to request this feature request.  Support relayed to me that it’s currently not possible.  The reply before this one shows only a single measure in the data set, not 2.  

Avocet
New Member

Running into a problem with measure vs. measure scatterplots - whenever filters are adjusted so that only one row returns, the visualization breaks and returns two points, one for each measure, both evaluated against the same axis (As opposed to one point measured against both the x- and y- axes.

Anyone else run into this and figure out a work around?

FYI @AA_Sacco  or anyone who has run into the same problem, I have been able to do this by converting the x-axis measure to a dimension in a new derived table while carrying the y-axis and name dimensions. Then in the explore of the derived table, pivoting on the name dimension that names each dot, so that the names come up as a legend. We can also size the dots in the visualisation options using the x axis dimension as long as you have the dimension declared as a type number. That should build the chart like the one in the doc.

PS: don’t forget to bind filter from the derived table to the source table

9e3645af-6499-4264-897e-971e5e284dae.png

Just stumbled upon this thread after not finding an easy way to create a simple scatterplot. Baffled as to why it has to be so complicated in 2021.

+1 on this feature request. I’ve run a k-means model using BigQuery and I’d like to plot 2 measures as a scatter plot and color them by the predicted clusters.

Totally ridiculous that the labels aren’t shown in tooltips. 

+1 to this. Cannot believe Looker has  Sunburst Sankeys etc but a level1 basic feature like coloring bubbles by label is not done.

Upvote. Need to be able to have the label display the values of a hidden dimension. (without complicated lookml workaround)

6 years has this thread. 6 Y E A R S

Totally ridiculous that the labels aren’t shown in tooltips. 

I totally agree, what am I supposed to do with this chart?

e9246c53-ef84-476a-8103-cdab0272c90b.png

There’s no way to distinguish any points, and theres a lot of points!

Joined to add to the mob.

I’m flabbergasted that the graphing abilities, and especially the scatterplot abilities are so primitive, having R scripts besides Looker to perform something so simple isn’t OK.  

Can y’all hire someone from Tidyverse to clean up the graphing in Looker please :sweat_smile:

Has there been any progress made here? I need to make a really simple measure vs. measure scatterplot consisting of only 10-15 points at any given time, but I need to add the dimension as labels. 

Use Case: Use two sales performance metrics measures for the X and Y on a scatter plot and add rep names as labels so we can see where they stack up against the team (top right quadrant is strong relative performance in both categories, bottom left quadrant is weak)

Sort of baffled this isn’t possible, as it would be very simple in tableau. 

+1. It’s a bummer having to tell your users that they’ll have to download the data in order to have a functioning scatterplot visualization.

Hi all, adding my +1 to this. For anyone still struggling with this, I was able to create somewhat usable scatterplot. Dots are still shown in the same colour and the legend is missing but hovering over each dot gives you what you’re looking for. See Scatterplot as a matrix | Looker Community

Is there any news on this feature request? Every other BI tool out there has this basic functionality without having to do workarounds. Honestly, what is a BI tool without a proper scatterplot functionality?

Hi this post is of great use, but how do I actually determine which parameter goes on which axis? I have two measures and when I do a scatterplot, the axis is switched. I want measure A as my x-axis and measure B as my y-axis but I’m only able to achieve the reverse. No matter how I align the measures A & B when I run the query, the plot generated seems to be the same.

I’m struggling here but it looks like lots of other people are to. Why when I pivot on a dimension does the Axes Selection section under Edit > Series on the Visualization disappear? I want to have a measure vs. measure scatterplot where the points are colored based on a dimension (pivoted or otherwise). Simple stuff but impossible in Looker.

Would love to be able to select what I use for the Value Labels too. Right now it only allows you to label based on the Y Axis, but really what I want is to label based on dimensions. Users have to hover over each dot to know what data it refers to, when for a scatterplot with only a few values in it I’d love to allow people to identify what the dimensions are (the source of that dot) without needing a hover over.

I have the same problem as dorianb below:
I would like measure vs measure + size by measure + colour by dimension (with a different dimension for the bubble identifiers).
I can get this working EXCEPT the colour by dimension part - just doesn't seem possible in Looker.

Looker Studio can do this so can we please update Looker with this capability too!

Thanks

Top Labels in this Space