Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
danderzei
Frequent Visitor

GROUPBY and reactivity

Hi,

I am struggling to build a grouped calculation that is reactive to user input. 

 

The GROUPBY formula I use is correct, but the calculation is not repeated when I change user input. I can filter the calculations themselves, but the results are static.

 

I built a proof of concept in Shiny (I am an R user trying to learn Power BI). The raw data is at the bottom. The top table shows the results of a grouped calculation. I hope it makes sense.

 

So the question is, how can I do a grouped calculation that is reactive to user input. How can I configure the system to repeat the grouped calculation every time the user input changes?

2 REPLIES 2
AlB
Super User
Super User

Hi @danderzei 

You can (see it all at work in the attached file.)

0. Place Table1[KPI] on a slicer

1. Place Table1[System] in table visual

2. Create 3 measures and place them in the visual

 

Complied =  SUM(Table1[CntComplied])

 

 

RTUs = SUM(Table1[CntRTUs]) 

 

 

KPI measure = DIVIDE([Complied], [RTUs])

 

3. Create 2 measures for the gauges ([KPI-1], [KPI-2])

4. You would still have to build a date slicer. Best would be to create a date table.

I've left that out because the figures you have as dates as from very long ago 1950s? so

there might be an error plus you have not explained the date slicer would interact with the

date fields in your fact table

 

Please mark the question solved when done and consider giving a thumbs up if posts are helpful.

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

Cheers 

SU18_powerbi_badge

 

danderzei
Frequent Visitor

Thanks for solving this problem. I have not been able to view your file just yet because it does not run on the Power BI version that IT provided. I have raised a ticket for them so hopefully, I can view your file soon. Thanks very much for your help.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.