Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Breezy
Creator II
Creator II

How to lable x-axis in chart?

Hi, for my example chart below (copied from a random page on the internet), how do I change: 2015, 2016, 2017 to label 

Y2015,Y2016,Y2017? How do I add the letter Y to the front?

 

Breezy_0-1672928357749.png

 

Labels (3)
1 Solution

Accepted Solutions
ogster1974
Partner - Master II
Partner - Master II

Create a calculated dimension ='Y'& [Year] as a master Item and use that are your dimension.

 

 

View solution in original post

9 Replies
Or
MVP
MVP

'Y' & Year, perhaps?

Might be a good idea to use Dual - Dual('Y' & Year, Year) - to keep the underlying numeric value.

ogster1974
Partner - Master II
Partner - Master II

Create a calculated dimension ='Y'& [Year] as a master Item and use that are your dimension.

 

 

Breezy
Creator II
Creator II
Author

Ok, I just made a master dimension for:

Master items -> dimension-> create new->field

'Y'&([Year])

When I go into my chart it does not appear as a field in the dropdown menu though. 

ogster1974
Partner - Master II
Partner - Master II

Did your Master Item error on creation of the expression?

Can you confirm the Dimension has been created successfully?

Can you screen shot it? Can you use it in a table chart?

Breezy
Creator II
Creator II
Author

You recommended 

Create a calculated dimension ='Y'& [Year]

I realize I can't use 'Year' since that is not the dimension. The dimension is 'Products'. My above chart is only an example but my real chart will not have Years as the x-axis. I was hoping there would be a formula that applies to all x-axis regardless of the dimension. 

ogster1974
Partner - Master II
Partner - Master II

From the look of your asks you are doing a simple sum(Sales) by Year and Product in a Grouped Bar Chart. Your ask was to add a Y to the Year Dimension.

Sounds straight forward enough.

 

Breezy
Creator II
Creator II
Author

I still can't get each each item on the x-axis to have the letter Y in front of them. Think of it this way - if it were not years on the x-axis - if instead it were animals: cat, dog, frog, I would want it to be Ycat, Ydog, Yfrog. 

 

ogster1974
Partner - Master II
Partner - Master II

I get the ask perhaps need to see more of your example to see where you're getting stuck. Screen shot scribble out any sensitive data in the snippet.

My solution would be the same. ='Y' & Animals as a calculated dimension in master items then add to chart.  What are you actually getting when trying to apply this solution It might help our understanding more and we can assist you better?

 

 

Breezy
Creator II
Creator II
Author

I got it now! Working 🙂

Thanks for your assistance!