Charting

Charting

Recommendation for best way to create this visualization

I have 2 columns 'years old when moved in' and 'Length of stay in Days' What I am looking to do is create a card (histogram?) that will take the ages and put them in buckets then show an average length of stay in days for each of those buckets. I already used the histogram to show the distribution of ages as a count, and it went smooth. Now trying to add this second layer to it has left me scratching my head.


image.png


Comments

  • You can utilize a beast mode to defined the different buckets and then drop your length column into your chart and use the average aggregate on it.

    1. CASE WHEN `Years old when moved in` >= 70 THEN '70+'
    2. WHEN `Years old when moved in` >= 70 THEN '60'
    3. WHEN `Years old when moved in` >= 70 THEN '50'
    4. WHEN `Years old when moved in` >= 70 THEN '40'
    5. ELSE '<30'
    6. END


    **Was this post helpful? Click Agree or Like below**
    **Did this solve your problem? Accept it as a solution!**

Welcome!

It looks like you're new here. Members get access to exclusive content, events, rewards, and more. Sign in or register to get started.
Sign In