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
Dunner2020
Post Prodigy
Post Prodigy

Selecting line graph

Hi there,

 

I am calculating the half-hourly average value using the following measure:

Average power = Average(Table[Power])

 

and plot the information in a line chart:

 

leo_89_0-1620588296400.png

The x-axis contains the time stamp and the y-axis contains the consumption. I want a selection option on the line chart as shown in the following picture (grey area):

 

leo_89_1-1620588527502.png

So that when I select the certain area of a line chart, it gives the difference between the start and end time of the x-axis and also add up the consumption of the selected area. 

I have no idea how to do that. Any help would be really appreicated.

 

 

5 REPLIES 5
Icey
Community Support
Community Support

Hi @Dunner2020 ,

 

Is this problem solved?

 

If it is solved, please always accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.

 

If not, please let us know and give us more details.

 

 

Best Regards,

Icey

@Icey the problem has not been solved

amitchandak
Super User
Super User

@Dunner2020 , With selection you can zoom, I doubt you can get diff.  Try this in tooltip

 

but measure like this can help


var _max1 = maxx(allselected('Date'), Date[Date])
var _min1 = minx(allselected('Date'), Date[Date])
return
calculate([measure], filter('Date', 'Date'[Date] =_max1)) -calculate([measure], filter('Date', 'Date'[Date] =_min1))

@amitchandak , how do you define [measure]?

Hi @Dunner2020 ,

 

Based on my understanding, the [measure] in the expression of @amitchandak stands for your meausre [Average power].

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.