Hello @Bourgoin,
The time spent in a specific status is recorded against the date when the issue leaves the specific status. These transitions are mapped against the “Transition Status” dimension.
The easiest way to filter out activities taking place within the last 90 days is to create a calculated member within the Time dimension. However, if you want to see the data on a weekly basis - you need to create that calculated member within the Weekly hierarchy of the Time dimension.
You might use the Transition Status dimension on report pages to select the specific status.
You might create the following calculated members and measures - Calculated measures and members.
A calculated member within the Time dimension Weekly hierarchy - “Weeks of last 90 days”. The expression might be as follows. Additional options are described in the comments.
Aggregate(
[Time.Weekly].[Week].DateMembersBetween(
--90 days ago is the last day to report + 6 days to include the week ending 89 days ago
--use "90 days ago" to show weeks starting within the last 90 days
"96 days ago",
--last sunday to avoid inclusion of the current ongoing week
--use "today" if you want to show the current ongoing week
"last sunday")
)
The measure for the “number of issues in scope” in the Measures dimension might directly refer to the distinct count measure “Transitions from status issues count”.
[Measures].[Transitions from status issues count]
However, if you might have an issue leaving the status several times within the same week and consider each “cycle” separately, then you might use the transitions measure “Transitions from status”.
[Measures].[Transitions from status]
Likewise - the standard measure “Average days in transition status” considers transitions separately, and the issue spending 2 days + 4 days in the status will have the average of 3 days. You might create a calculated measure - “Average days of issue in transition status” within the Measures dimension with the following expression.
CASE WHEN [Measures].[Transitions from status] > 0 THEN
[Measures].[Days in transition status] /
[Measures].[Transitions from status issues count]
END
Since each separate “cycle” of the issue in status is not recorded as a separate entity, the Standard deviation can only be calculated on the level of issues. Since the calculation requires at least two entries, an the expression is wrapped within an additional condition.
The expression might be as follows.
CASE WHEN
--standard deviation requires more than one member for calculation
[Measures].[Transitions from status issues count]>1
THEN
StDev(
Filter(
DescendantsSet(
--set of issues
[Issue].CurrentHierarchyMember,
[Issue].[Issue]),
--filter condition - issue left status within the current Time member
[Measures].[Transitions from status]>0
),
--numeric value for Standard Deviation - days in status for the current issue in iteration
[Measures].[Days in transition status]
)
END
Regards,
Oskars / support@eazyBI.com