Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have one bar chart with two dimensions
1) MonthYear (which has values like Jan 2010, Feb 2010, etc)
2) Type (which has values 'A', 'B' and 'C')
The expression shows the count of books for selected date range (I have two calender objects for that) for the respective monthyear and type.
It is working fine, but what I need to display is percentage of each type of books for respective months.
For e.g. in Jan 2010; there are total 500 books, out of which 100 are of type A, 200 each of type B and C.
I want to display for Jan 2010, for type A, 20%, for type B and C 40% each. This should vary as per the count of books for other months.
I am not getting how to achive it. Could you please help me out? Thanks in advance.
My expression is
=count({<Date = {">=$(vFromDate) <=$(vToDate)"}>} BookID)
(As I am having personnel edition of qlikview; I will not be able to open any external .qvw file)
Hi,
Can you able to attach sample data and image of the chart that shows wrong %?
Celambarasan
Hi,
The content in the attached file is
Load Script:
LOAD * INLINE [
MonthYear, BookID, Count
Jan 2010, A, 45
Jan 2010, B, 56
Jan 2010, C, 54
Feb 2010, A, 21
Feb 2010, B, 42
Feb 2010, C, 32
];
In Straight table
I used MonthYear and BookID as dimensions.
Expression : =Sum(Count)/Sum(Total<MonthYear>Count)
Hope this helps you.
Regards,
Jagan.
Hello
Not sure I understand, but what would I do (TOTAL-A) / A and (TOTAL-B) / B and percentage checkbox
I hope that helps
Hey, my problem got solved. I used divisor as Total BookId.
Thanks all for your help.
2012/2/13 Gabriel Vázquez <qliktech@sgaur.hosted.jivesoftware.com>
**
QlikCommunity <http://community.qlik.com/index.jspa>
Re: Calculating percentage value in a chart
created by Gabriel Vázquez<http://community.qlik.com/people/gabriel.vazquez>in
New to QlikView - View the full discussion<http://community.qlik.com/message/191041#191041>