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
Anonymous
Not applicable

Visualisation

Hi all,

This is my Matrix visual. Is it possible to create a column in Matrix visual?

I would like to create a calculated column, the total of each part number to be divided by Part count (907). 

 

I cannot do that in the data field as the view of the data is different.

Megha3012_0-1641812940461.png

 

Any help would be appreciated!

 

Thank you!

Megha

2 ACCEPTED SOLUTIONS

Hi, @Anonymous ;

Try it.

Day Count =
CALCULATE (
    DISTINCTCOUNT ( 'Demand history & VVA'[DemandDate] ),
    ALL ( 'Demand history & VVA' )
)

Best Regards,
Community Support Team_ Yalan Wu

View solution in original post

Anonymous
Not applicable

Hi @v-yalanwu-msft 

 

Thank you so much!🙂

View solution in original post

13 REPLIES 13
v-yalanwu-msft
Community Support
Community Support

Hi, @Anonymous ;

You could create a measure add it to matrix ,then adjust the spacing of visual fields.

1.create a measure.

AVERAGE Daily = DIVIDE( SUM([Value]),COUNT('Table'[Cate]))

2.off these funtions.

vyalanwumsft_0-1642059197867.pngvyalanwumsft_1-1642059217973.png

3.then Manual spacing adjustment.

vyalanwumsft_2-1642059424771.png

The final output is shown below:

vyalanwumsft_3-1642059444803.png

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi @v-yalanwu-msft Thank you so much!

I just have an other query.

 

Average Daily Use = DIVIDE(SUM('Demand history & VVA'[Quantity_1]),DISTINCTCOUNT('Demand history & VVA'[PartNumber]))

 

Megha3012_0-1642092926346.png

 

Why is the Average daily Use repeating what's in Total of Quantity_1?

How can I correct that?

 

Thank you!

Megha

 

Hi, @Anonymous ;

You could try modify it.

Average Daily Use =
DIVIDE (
    SUM ( 'Demand history & VVA'[Quantity_1] ),
    CALCULATE (
        DISTINCTCOUNT ( 'Demand history & VVA'[PartNumber] ),
        ALL ( 'Demand history & VVA' )
    )
)

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Thank you! @v-yalanwu-msft 

But there was a small mistake in the formula I had put.

The formula I am using now is given below:

Average Daily Use = DIVIDE (SUM ( 'Demand history & VVA'[Quantity_1] ), 90)
 
But the same formula if I write it as 
Average Daily Use = DIVIDE (SUM ( 'Demand history & VVA'[Quantity_1] ), [Day Count]) )
I dont get the right answer.
 
Can I know why's that?
 
[Day Count] is a measure I created.
 
Thank you!
Megha

Hi, @Anonymous ;

Can you share the formula for [Day Count] and the result returned?Or a simple data after removing the sesentive information?
According to the information you provided, I cannot accurately judge the reason for the error, but I guess it is caused by the context. Maybe you need to add ALLSELECTED() or ALL () to your count. Could you try the following or provide more information?
Looking forward to your reply !

 

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi @v-yalanwu-msft,

The formula for DayCount is 

Day Count = DISTINCTCOUNT('Demand history & VVA'[DemandDate]). 
The result returned is 90.
Thank you!
Megha

Hi, @Anonymous ;

Try it.

Day Count =
CALCULATE (
    DISTINCTCOUNT ( 'Demand history & VVA'[DemandDate] ),
    ALL ( 'Demand history & VVA' )
)

Best Regards,
Community Support Team_ Yalan Wu

Anonymous
Not applicable

Hi @v-yalanwu-msft ,

 

On similar basis, this is the formula I have used for working days.

Working days = CALCULATE(
DISTINCTCOUNT('Demand history & VVA'[DemandDate].[Date]),
FILTER(
'Demand history & VVA',
'Demand history & VVA'[IsWorkingDay] = "TRUE"
))
the result returned is 65.
 
Now, I need to calculate Average daily usage.
The formula for that is:
Average Daily Use = DIVIDE([Total Volume],[Working days]).
 
But,
 
I get the right answer only when I give the formula as: 
Average Daily Use = DIVIDE([Total Volume],65).
 
Can I please know how to correct that? I would like to use the measure [working days].
 
Thank you!
Megha
Anonymous
Not applicable

Hi @v-yalanwu-msft 

 

Thank you so much!🙂

vanessafvg
Super User
Super User

can you share some data in text format?  

 

can you also demonstrate what you expect to end up with via an example?





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




Anonymous
Not applicable

Hi @vanessafvg,

I have attached the excel sheet. I am expecting like this.

Megha3012_0-1641818606171.png

The column Average daily use is derived by dividing volume by the part number count.

i.e., in the first row, it is 3288.87/978. 

 

Is it possible in Matrix visual?

 

Hi you haven't shared the data in text format, thats another screenshot.

 

 





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




Anonymous
Not applicable

Apologies!

Attaching in text format.

There are still a lot of date columns. It wasnt possible to copy the whole. The column 'Volume' shows the sum of all the dates.  

12/26/202112/27/202112/28/202112/29/2021 VolumeAverage Daily Use
4833.3460533.346050 3288.8736.54296
0.424090.4240900 93.161.03508
0.18024000 91.981.02198
4819568280 392375.004359.72222
0000 0.000.00000
0000 77.690.86321
0000 4.890.05429

 

Thank you!

Megha

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.