Average Sprints all the project issues have gone through

Hello, people!

I’m struggling to create a calculated measure to identidfy the average number of sprints all the completed issues have gone through.

First, I created this measure:

COUNT(
    [Sprint].[Sprint].getMembersByKeys(
    [Issue].CurrentHierarchyMember.get('Sprint IDs')
    )
)

But, I don’t know how to calculate this for the entire project. I’ve tried to understand the documentation, but this is not very clear.

Can anyone help me?

Cheers,
Marcelo

1 Like

Hi @marcelomlo1,

The measure you have created would return the count of sprints for an issue, yes. The next step is to use the Avg(…) function to specify over what set you wish to get the average on higher levels. Please try the following:

Avg(
  Filter(
    Descendants([Issue].CurrentMember, [Issue].[Issue]),
    [Measures].[Issue Sprints] <> "(no sprint)" AND
    [Measures].[Issues created] > 0
  ), 
  Count([Sprint].[Sprint].getMembersByKeys(
    [Issue].CurrentHierarchyMember.get('Sprint IDs')
  ))
)

Lauma / support@eazybi.com

1 Like

Hello, @lauma.cirule

Thanks for your help. This was exactly what I was looking for.

Regards,
Marcelo

1 Like