Forum Discussion
PowerBI Desktop
How do I get the MTBF for all those necessary Equipments for each respective months?
I have no idea how this would logically even be possible.
Please provide sample data that fully covers your issue.
Please show the expected outcome based on the sample data you provided.
| Equipment | Commissioned Date | BreakDown Date |
| A | 02/01/2024 | 03/15/2024 |
| B | 01/01/2024 | 02/01/2024 |
| C | 01/15/2024 | 02/15/2024 |
| A | 02/01/2024 | 02/28/2024 |
| B | 02/20/2024 | 03/20/2024 |
| C | 03/01/2024 | 03/27/2024 |
Hello lbendlin ,
I have added a dataset to recalculate the MTBF for February and March 2024. I am fine with your earlier formula of
MTBF = var a = values('MergedTable'[BreakDate]) return if(HASONEVALUE(MergedTable[Equipment]),DIVIDE(maxx(a,[BreakDate])-minx(a,[BreakDate]),COUNTROWS(a)-1))
But this time, I want the MTBF for February and March of 2024 instead of individual equipments.
Can you please suggest the DAX code in consistent with the formula above?
Thank you again!
- lbendlin1 year agoSuper User
I want the MTBF for February and March of 2024I don't know what that means. Do you want the MTBF for equipments that were commissioned in these months?
- Anonymous1 year agoNot applicable
Hello lbendlin ,
Yes, I want the MTBF on the Y-axis and Months on the X-axis. MTBF should include all the Equipments for that particular month.
Thank you!
- Anonymous1 year agoNot applicable
Hello lbendlin ,
I am just following up to see if you have made any progress to figure it out?
Thanks
- lbendlin1 year agoSuper User
What does " for that particular month. " mean? Commissioned in that month? Having a failure in that month?
- Anonymous1 year agoNot applicable
Hello lbendlin ,
Since we are calculating Mean Time Between Failure, I think we should use BreakDate for that particular month which should be the X-axis.
Thanks,