Tutorial: Stephen Few-style bullet chart in Power BI using core visuals!

Поделиться
HTML-код
  • Опубликовано: 2 авг 2024
  • Bullet charts in tables for easy comparison between rows are something that is highly promoted by Stephen Few as a best-practice design. Thanks to the February Power BI feature update, it's now possible to do this with free visuals and make it actually look good! This works great for goal-to-actual reporting, which is what I'm demoing in this tutorial video. This uses DAX, but does not require an in-depth knowledge of it to use.
    Here's the code used (using a github link as RUclips doesn't like the special characters in the DAX). Theoretically speaking, you should just be able to copy/paste this into a measure and replace the sales/goal measures with your own, and you should be good to go. :)
    github.com/chpayton/BI-Files/...
    The DAX is a modified version of Kerry Kolosko's progress bars. You can check hers out here:
    kerrykolosko.com/portfolio/pr...
    0:00 Intro
    2:00 DAX
    5:51 Settings/configuration
  • НаукаНаука

Комментарии • 24

  • @Kidpambi
    @Kidpambi Год назад

    This is just delightful

  • @djenral6153
    @djenral6153 Год назад +1

    top
    many thanks

  • @calvinchoi4300
    @calvinchoi4300 Год назад

    Is there a way to adjust the length of the bullet chart so that it's longer? I tried playing around with the parameters in the SVG code but I've only managed to make it shorter not longer.

    • @bi-ome
      @bi-ome  Год назад

      Yes, you would just need to update both the visual setting for image width and the DAX (the percentage variables and the width of the rectangle in the SVG. You may also have to drag the column wider, I don’t think it auto-adjusts.

  • @vijayantoinemick9713
    @vijayantoinemick9713 Год назад

    Hi @Christine Payton, great Power BI report! Where can we get this example report on download ? Please

    • @bi-ome
      @bi-ome  Год назад +3

      Thanks! I uploaded the PBIX here: github.com/chpayton/BI-Files

    • @djenral6153
      @djenral6153 Год назад

      @@bi-ome useful stuff..!

  • @micahfaas
    @micahfaas Год назад

    This is super cool! Do you know of a good source for other types of visual SVGs?

    • @bi-ome
      @bi-ome  Год назад

      Yeah, Kerry Kolosko’s site has a bunch of good ones. kerrykolosko.com/portfolio-category/svg-templates/

  • @kaitvaughn1377
    @kaitvaughn1377 Год назад

    This was super awesome! I was wondering if there was a way to change the color of the bar? For example, if the actual exceeds the target, make it green, otherwise orange?

    • @bi-ome
      @bi-ome  Год назад

      Almost certainly, with an IF() - I’ll play around with it :)

    • @kaitvaughn1377
      @kaitvaughn1377 Год назад

      @@bi-ome thank you! I’ve been trying it in the return statement of the Dax with no avail.

    • @bi-ome
      @bi-ome  Год назад

      @@kaitvaughn1377 Here you go - I added a variable for barcolor with the if-statement, then used that where the bar color goes in the SVG code. If you put the "if" in the return statement, you'd need to duplicate the whole set of SVG code (one version with each color): github.com/chpayton/BI-Files/blob/main/SVG%20Bullet%20Chart/SVG%20Goal%20Progress%20-%20Color%20Changing.txt

  • @alexdenhaan5383
    @alexdenhaan5383 6 месяцев назад

    Hi @christine, Thanks for this great example.
    When I implement this to a personal report, the images are not correct though!? Target is always on begin or end and actual is empty or full depending on values.
    If I add my testdata (just created a simple table by entering data) into your example report, it works fine😲
    I checked if there are any differences in report settings but can't find any diffences.
    Anyone a suggestion what is causing it not to work in my personal reports?

    • @bi-ome
      @bi-ome  6 месяцев назад +1

      There are some references in the DAX to things in the data model, so you do need to update those references - it's hard to say without seeing the code/model.

    • @alexdenhaan5383
      @alexdenhaan5383 6 месяцев назад

      @@bi-ome, Thanks for your reply.
      I found what was causing the issue. In my personal report the model language (Culture) was Dutch (nl-NL). In dutch we use a comma as a decimal seperator instead of a point.
      This resulted into the width of either the fill or marker to be defined as width=' instead of width='.
      Since it is not possible to change the culture of an existing report with Power BI Desktop this can be resolved by changing measure to replace the comma with a point or round the vallues used:
      VAR PERCENTAGEFILL = SUBSTITUTE ( MAXActual/AXISRANGE*118, ",", "." )
      or
      VAR PERCENTAGEFILL = ROUND ( (MAXActual/AXISRANGE*118), 0 )

    • @bi-ome
      @bi-ome  6 месяцев назад

      @@alexdenhaan5383 Interesting, good catch!

  • @Mrjoseoasis
    @Mrjoseoasis Год назад

    Hello! I tried this by comparing sales and goals by year and month but I get an error. If sales are greater than goal, the bar is full gray but the vertical organge bar is only at the start of the chart; if sales are less than goal, the bar is empty and the orange vertical is at the end. In this data I have sales and goals from 2015-2019, this has something to do? I ask tis because in your example you only use last fiscal year.

    • @bi-ome
      @bi-ome  Год назад

      It's hard to say without looking at your code. As long as the SVG is referencing your measures and they are both the same timeframe (whatever that timeframe may be) I would expect it to work. Is it possible that you forgot to update one of the pieces of the template when you replaced your measures?

  • @HelenaGH
    @HelenaGH 2 месяца назад

    How can I hide the text that appears when you leave the mouse on the inside bar? =(

    • @bi-ome
      @bi-ome  2 месяца назад

      You can't that I'm aware of, currently, but you can add a custom tooltip to override it. I did submit feedback in a few places on this because I agree it's super lame...