Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
yashcena
Contributor III
Contributor III

Show ratio in simplest form

I'm working on an analytics app which has information about scrum team, resources and their roles (developer, tester, dba etc.)

I have to show the ratio of developers to testers for each scrum team in the simplest form (Ex: 4 dev & 6 testers = 2/3).

For now, I'm just showing the count(dev) '/ ' count(tester) which is simply displaying both the counts with a '/' in between. No calculation is being made.

What do I need to do to get the simplest ratio? Is it possible at all?

Hope I have made my requirement clear.

Thanks,

YASH

7 Replies
ahaahaaha
Partner - Master
Partner - Master

Hi,

Why quote?

count(dev) / count(tester)

yashcena
Contributor III
Contributor III
Author

if i dont give the quote, it simply divides the two counts. I want it in x/y or x:y format

ahaahaaha
Partner - Master
Partner - Master

Expression count(dev) / count(tester) should work. Is it possible to have several rows of data on which you are calculating?

yashcena
Contributor III
Contributor III
Author

This expression works fine. But the issue here is this:

For 5 dev and 10 testers, that expression would return 0.50. I want 1:2 i.e. 5/10 in simplest form

ahaahaaha
Partner - Master
Partner - Master

May be


count(dev)&' /'& count(tester)

yashcena
Contributor III
Contributor III
Author

I'm using this expression itself now. So 5 dev and 10 tester would give me 5/10 in the chart. I want to see 1/2 which is the simplest form of 5/10.

5'/'10 would display 5/10 in the chart.

just 5/10 would display 0.50 in the chart

What do I need to write in the expression dialogue box so that 1/2 or 1:2 is displayed?

eknezo24
Contributor II
Contributor II

I used this and it worked for me!

Count([dev])&' : '& count([tester])