Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Excluding a value from a dimension

Hello

I would like to exclude a value within a dimension when I do a graph/table.

For example, my dimension is "Age" and I have three categories: "24 and below", "25 and over" and "Other".

What should I do to exclude "Other" from a graph/table?

I would like to exclude it in a particular chart/table and not the whole data-set uploaded.

Thanks

Ewa

11 Replies
Anonymous
Not applicable
Author

you can define as calculated dimension

if (Age <> 'Other', Age)

of you can use set Analysis in expression

sum([Age-={'Other'})yourfield

Kushal_Chawda

use below expression

=sum({<Age-={'Others'}>}Value)

Not applicable
Author

Thanks for your suggestions.

I have a chart that shows various dimensions (depending on the button you select) for the same calculation/expression. Hence each dimension have a variable assigned to it (so that buttons work fine).

Hence the option with an expression will not work I think.

When I do a calculated dimension (if (Age <> 'Other', Age) and assign a relevant variable to the dimension, the chart still shows the "Other", the only thing that disappears is the label from the legend.

Any thoughts?

avinashelite

try like this

=sum({<Age={'*'}-{'Others'}>}Value)


or

=sum({<Age-={'Others'}>}Value)

Anonymous
Not applicable
Author

attach a small sample qvw

what do you mean assign a relevant variable to the dimension??

Not applicable
Author

Hello

I'm not quite sure how to generate a small sample qvw, would the snapshots suffice?

I'm trying to get rid of "Unknown" in the chart below.

Thanks

Ewa

1.png2.PNG3.PNG

sasikanth
Master
Master


try some thing like

sum({<attempt={1},OUTCOME={'COMPLETE'},[Ethinicity General]={'*'}-{'Unknown'}>} FPE)/sum({<[Ethinicity General]={'*'}-{'Unknown'}>}FPE)


OR

Calculate the same at script level

Load * ,

IF(Age<>'Others',Age) as New_Age ;

Load Age,.,.,.,.,,. From Tab;

sangeethag
Contributor III
Contributor III

Hi,

try to exclude in expression level. add below in your expression

{<Age-={'Others'}>}

Anonymous
Not applicable
Author

Change your Expression to

= sum({<[Ethnicity general]-={'Unknwon'},[Attemps]={"1"},[Outcome]={"COMPLETE"}>} [FPE] / sum({<[Ethnicity general]-={'Unknwon'}>})

EthnicityGeneral must be defined in both part of Expression

if you Need Ethnicity General included in the second sum (divide) you Need to use aggr function