10 Replies Latest reply: Jul 13, 2015 11:26 AM by Sunny Talwar

# Restrict How Many Shown on X-Axis

I have a chart where the week number is the x-axis, and I wish to show the most recent 10 weeks.

I would usually do this by using a calculated dimension to restrict to 10 weeks, but my expressions use calculations which go back more than 10 weeks.

I hoped to use Dimension Limits, but it seems I can show the First 10 values, but there's no option to show the Last 10.

Any ideas are welcome.

• ###### Re: Restrict How Many Shown on X-Axis

You can continue to use First, but change the sort (if it is ascending, then make it descending and vice versa) and the last 10 should be visible. Here is from the help page of QV.

HTH

Best,

Sunny

• ###### Re: Restrict How Many Shown on X-Axis

Hi

Thanks - I understand better now how the limit works. I have taken your advice, and it does show me only the values along the x-axis (dimension). Unfortunately, my expression values are then incorrect - p[perhaps this is because I use RangeSum() and my range goes beyond the restricted dimension limit ?

• ###### Re: Restrict How Many Shown on X-Axis

Are you using above function with RangeSum()?? If you are, then you might have to switch Above() with Below() because the sorting changed now.

• ###### Re: Restrict How Many Shown on X-Axis

Hi

Yes, I'm using RangeSum() with Above().

But Week is my first expression, and therefore the one used by the Dimension Limits, so I can choose to limit the Largest 10 values, without changing my sort sequence.

However, it isn't showing the correct results, so I do think my range is affected by the dimension limit

• ###### Re: Restrict How Many Shown on X-Axis

Not sure I understand completely. Do you have a sample you can share?

• ###### Re: Restrict How Many Shown on X-Axis

My table (currently) has rows for weeks 1- 28.

My expression use RangeSum to add the values for the week and the previous 9 weeks.

So for week 28, the value is the sum of weeks 28-19.

I can use dimension limits to show 10 weeks of values, ie. weeks 28-19. But it appears that the Range expression value is incorrect because of the 'missing weeks' ie.

Week 27 value is the sum of weeks 27-19,

Week 26 value is the sum of weeks 26-19,

Week 25 value is the sum of weeks 25-19   etc.

• ###### Re: Restrict How Many Shown on X-Axis

The idea makes sense. I have not used Dimension limits to know what the issue is, but I can suggest restricting the number of weeks to see using set analysis. If you can provide some sample data, I can show you how it can be done.

Best,

Sunny

• ###### Re: Restrict How Many Shown on X-Axis

Hi Richard.

in dimension limits you can use the largest option, and have week as you first expression. This way you will only show the latest 10 weeks.

Dimension limits are applied on the first expression.