Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
 techvarun
		
			techvarun
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi Folks
am designing a barchart which is having a dimention "=class([Overdue Days],30)" but in this clasification i have a data range "-30<=x<= 0" i want to display only positive range.
Please anyone help me out its urgent
 
					
				
		
.png) hic
		
			hic
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		=class(RangeMax([Overdue Days],0),30)
 
					
				
		
.png) hic
		
			hic
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		=class(RangeMax([Overdue Days],0),30)
 
					
				
		
 techvarun
		
			techvarun
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thanks Henric,
                    It worked like a charm  .
. 
I have one more doubt, how to set the upper limit in class function?
may be i dont want the days after 120 what condition do i need to write.
Thanks in Advance
 
					
				
		
.png) hic
		
			hic
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		There are several ways to do this, but I would probably go for
=If( [Overdue Days]>120,
Dual('>120',130),
Class(RangeMax([Overdue Days],0),30)
)
And I would do it in the script. There is no need to calculate this array more than once. If you instead use a calculated dimension to define it, this calculation would steal cpu-power every time you click.
HIC
 
					
				
		
 techvarun
		
			techvarun
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thank you HIC
 
					
				
		
 techvarun
		
			techvarun
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Just noticed that It is clubing the negative values to the range 0<=x<=30 
I want the range values "-30<=x<= 0" should be removed from the chart.
Please anyone help me its urgent
Regards
 
					
				
		
.png) hic
		
			hic
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Yes, that is what the RangeMax does. If you instead want to remove them altogether, use
=If( [Overdue Days]>120,
Dual('>120',130),
If( [Overdue Days]>0,Class([Overdue Days],30))
)
HIC
 
					
				
		
 techvarun
		
			techvarun
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thanks HIC
     I have tried this 
 =If( [Overdue Days]< 0,
Dual('>0',130),
Class(RangeMax([Overdue Days],0),30)
)
but one problem is it is showing only odd number expressions like 30,60(missing),90,120(missing),150.
any correction to be made?
Regards
 
					
				
		
 techvarun
		
			techvarun
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Sorry HIC by this formula am getting the values but still it is showing the values less than zero
attached is the result image
please clarify. btw why we are using the number 130 in this formula?
Regards
 
					
				
		
.png) hic
		
			hic
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		You need to assign NULL to values below zero. You now assign 130 displyed as '>0' to these. Further, you wanted to group everything greater than 120 in one class, for which I suggested a Dual('>120',130), i.e. the numeric value is 130 but it is displayed as '>120'.
Isuggest you try
=If( [Overdue Days]>120,
Dual('>120',130),
If( [Overdue Days]>0,Class([Overdue Days],30))
)
which does both of the above things.
HIC
