Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
danielact
Partner - Creator III
Partner - Creator III

Show only certain labels on the X axis

I have a line chart which is showing information for all employees of a company. My dimension is EmployeeName, and my expression is BonusPercent. I want to see all the data points, but I only want to show the name on the axis for certain employees - the ones who get a Bonus of more than 10%. Is there a way to keep all the data points showing, but only see labels for the specific employees?

13 Replies
bbi_mba_76
Partner - Specialist
Partner - Specialist

Hi,

I think you could play with the dimension font color, to set it as the background to hide some employee name

MK_QSL
MVP
MVP

Instead of using EmployeeName...

Use Calculated Dimension...

IF(Aggr(SUM(BonusPercent),EmployeeName)>= 10%, EmployeeName)

Rest all same.

Anonymous
Not applicable

Daniel,

Try to use conditional color for this label, so it is white when the condition is not met.  The color is here:

Chart Properties - Axes - Dimension Axis section - Font - Color - Calculated....

Regards,

Michael

Anonymous
Not applicable

Manish,

Using calculated dimensions would remove data points, which is not desired (if I got the requirement right).

Regards,

Michael

Anonymous
Not applicable

Daniel

Looks you have a fair few suggestions already.

I often do things like this by disabling the standard legend, [untick the Show Legend on the Dimension tab].

Then I create a new expression and under Display Options, have Text as Axis selected and nothing else.  And in the expression set any Employees with bonus < 10% to null and the rest to the Employee Name with an if statement.

This also has the advantage that you can create text for the expression that has a chr(10) [line feed] in it, so if you have a horizontal multi line legend you can fit it on better.

Best Regards,    Bill Markham

MK_QSL
MVP
MVP

Dear Daniel,

You are right.... my suggestion will not work..

Dear Bill, Can you post a sample example?

danielact
Partner - Creator III
Partner - Creator III
Author

Thanks Bill, that looks like it can work. One other question - is there a way to make that text vertical?

sureshbaabu
Creator III
Creator III

Hello, please set dimension axis to vertical on Axes tab.axis.png

danielact
Partner - Creator III
Partner - Creator III
Author

I already have that set. Since this is pulling values from an expression, not a dimension, that setting doesn't apply.