Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Percentage calculation based on value in a custom field

Trevor Brace January 11, 2024

I created a custom field in my Jira cloud instance. It is type 'Checkboxes'. It will either be left unchecked, or checked 'Yes'.

I now want to create a filter (or other gadget for a dashboard) that will show me the following calculation, as a percentage:

  • number of stories in the current sprint with yes checked / total number of stories in this sprint

Is this possible? I'm assuming I'll need to use ScriptRunner or some other plugin, but not really sure where to start.

3 answers

3 accepted

3 votes
Answer accepted
Jack Brickey
Community Champion
January 11, 2024

Hi Trevor,

Can you try creating a dashboard and adding a single pie chart gadget, and associate your project as the filter. Then select your custom field as the statistic if available. Disclaimer – I have never tried to use a checkbox custom field as a statistic in dashboard gadgets. Please let me know the results. I may give this a try as well.

1 vote
Answer accepted
Mykenna Cepek
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 13, 2024

Also, the "Issue Statistics" dashboard gadget in Jira will give you both counts and a percentage. It's a bar chart, rather than a pie chart, but it might fit your original requirements better. And it takes up less space:

Untitled.png

Jack Brickey
Community Champion
January 14, 2024

Good call. I like that gadget.

Like Mykenna Cepek likes this
Trevor Brace January 15, 2024

Very cool, and nice to have the counts and percentage without interacting.

0 votes
Answer accepted
Mykenna Cepek
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 11, 2024

The simplest thing I can think, available in standard Jira (all versions, AFAIK) is to create a new Jira Dashboard, add a Pie Chart gadget, configure it on the project, and select your custom "Checkboxes" field as the "Statistic Type". Here's what it looks like for another "binary" field:

Capture.PNG

Jack Brickey
Community Champion
January 11, 2024

Great minds...😉

Like Mykenna Cepek likes this
Trevor Brace January 11, 2024

Ah, elegant! This will actually work. You have to hover to display the percentage, but I can live with that. Thanks!

Jack Brickey
Community Champion
January 11, 2024

Precisely! Glad it worked out.

Trevor Brace January 11, 2024

I ended up creating a custom filter to use in the pie chart so I can limit the results to the currently open sprint. Works great...thanks again!

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events