Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to create Bucket

Can anybody please tell me how to create bucket

my expression is sum(z5)/sum(z6)*100

i have to create four bucket i.e 0-90,90-95,95-100

Please help me out

12 Replies
m_woolf
Master II
Master II

Look at the class function in help.

Not applicable
Author

hi ,u can do the following in script :

if ((sum(z5)/sum(z6))*100)>0 and ((sum(z5)/sum(z6))*100)<=90, '0-90',

if((sum(z5)/sum(z6))*100)>90 and ((sum(z5)/sum(z6))*100)<=95,'90-95',

if(((sum(z5)/sum(z6))*100)>95 and ((sum(z5)/sum(z6))*100)<=100,'95-100')))

i hope it workz

Anonymous
Not applicable
Author

You can also use what kuki_kuki_87 is suggestion as a calculated dimension in your charts.

jagannalla
Partner - Specialist III
Partner - Specialist III

Hope it helps you.

Use this as three different expressions, It gives each bucket wise.

0-90 ->  Sum({$<BucketFieldName={">=0<90"}>} Z5) / Sum({$<BucketFieldName={">=0<90"}>} Z6) *100

90-95 ->  Sum({$<BucketFieldName={">=90<95"}>} Z5) / Sum({$<BucketFieldName={">=90<95"}>} Z6) *100

95-100 ->  Sum({$<BucketFieldName={">=95<100"}>} Z5) / Sum({$<BucketFieldName={">=95<100"}>} Z6) *100

Not applicable
Author

Can u explain what u mean by BucketFieldName?

jagannalla
Partner - Specialist III
Partner - Specialist III

It is the fieldname which you want to apply buckets i.e, ranges 0-90,90-95.95-100.

Not applicable
Author

kkk

nilesh_gangurde
Partner - Specialist
Partner - Specialist

Hi sumitthakur.mpvm,

You can craete bucket at load time which and use it as Dimension with the above mension expression(sum(z5)/sum(z6)*100).

write the following script in the load :

if (FieldName <= 90,'0 - 90',if(FieldName >90 and FieldName <= 95,'90 - 95',if(FieldName > 95 and FieldName <=100,'95 - 100'))) as Bucket,

Then Dimension = Bucket And Expression = sum(z5)/sum(z6)*100)

Regards,

Nilesh Gangurde

Not applicable
Author

hi can u explain bucket analysis for interview purpose