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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Custom Measure for Bar Chart Upper/Lower Bound Error Bar Limits - New to DAX , pls help :)

Hi -- I ran an OLS regression w/ an 80/20 split in python and added a bar chart of the predictor coefficients to Power Bi. I'd like to add error bars using the SE or upper/lower limits from the regression summary - I am struggling miserably. 

 

This is data I pulled from the model summary and added as a new table to Power Bi

 

Puchi_0-1676083774861.png

 

I've added the upper and lower bound variables as fields in the error bar section:

 

Puchi_1-1676083929320.png

 

But the auto-sum of the fields ruins the whole approach 😞

Adding all the error bars to 1

Puchi_2-1676084104091.png

I'm pretty new to DAX...I've been trying to play around calculating the measure for the upper/lower bounds with SWITCH(TRUE(), but I'm only slightly familiar with doing this for slicers and combining it with the SELECTEDVALUE() or CROSSFILTERRED() functions.

 

Any help would be a blessing! Thank you :')

1 REPLY 1
v-jianboli-msft
Community Support
Community Support

Hi @Anonymous ,

 

Do you mean that the values shown for the upper and lower limits are incorrect? From the screenshot you provided, they appear to be in text format? Please try changing them to a numeric format and then use an aggregation such as MAX\MIN\SUM.

 

For more details, please refer to:

Work with aggregates (sum, average, and so on) in Power BI - Power BI | Microsoft Learn

 

Best Regards,

Jianbo Li

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

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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