Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have data in below format:
Member Var1 Var2 Var3 Var4 Var5 Var6 Var7 Var8 Var9 Var10
a 0.70 0.14 0.09 0.74 0.17 0.33 0.71 0.15 0.01 0.65
b 0.88 0.14 0.84 0.70 0.92 0.43 0.05 0.48 0.91 0.90
c 0.05 0.49 0.89 0.58 0.64 0.65 0.13 0.31 0.75 0.67
d 0.59 0.71 0.10 0.57 0.35 0.63 0.93 0.20 0.65 0.45
I want to display above data in a bar chart where X-axis should show me Var1 Var2 and so on and each bar for the variables should be the count of values greater than 0.50. e.g. Bar for Var1 would have a count of 3 and Bar for Var2 would have count of 1
Is this possible?
Thanks in advance
Abhinav
Hi Abhinav
Try to transform your data using CrossTable() function first. Then creating your chart is going to be fairly easy
Lukasz
Post a sample or explain in more words
Load like this:
CrossTable(Var, Value)
LOAD Member,
Var1,
Var2,
...
Var10
FROM ...;
Create chart with dimension Var and expression
=Sum({<Value = {">0.5"}>} Value)
HTH
Jonathan
This should work for you. In the script:
CrossTable(Var, Value)
LOAD Member,
Var1,
Var2,
Var3,
Var4,
Var5,
Var6,
Var7,
Var8,
Var9,
Var10
FROM yoursource.qvd (qvd);
As a result for this script, you will get a table like:
Member Var Value
a Var1 0.70
a Var2 0.14
a Var3 0.09
......
Then, create a barchar object with Var as dimension and =Count({<Value = {">0.5"}>} Value) as expression.
Hope that helps.
Luis
Thank you everyone.