Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

On Demand Webinar: See Why Thousands of QlikView Users Have Switched to Qlik Sense. REGISTER
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Scatter charts and ranges

How can I create ranges to select data in my scatter chart?




31-40k etc...

Do I need to code this via an inline load? how can I apply this to my scatter graph?

Many thanks

6 Replies
Master III
Master III

you need to range this either by function() or by nested if statement as

   if (sales>0 and sales<=20000,'20+K',----

And just do this in the script and use that derived field as Dimension in your UI


Make buckets or you can use  calculated dimension



if(Salevalue > 20000, '20k+',

if(Salevalue >=21000 and Salevalue <= 30000,'21-30k',

if(Salevalue >=31000 and Salevalue <= 40000,'31-40k'))) as Bucket

2. you can use it as calculateddimension

if(Salevalue > 20000, '20k+',

if(Salevalue >=21000 and Salevalue <= 30000,'21-30k',

if(Salevalue >=31000 and Salevalue <= 40000,'31-40k')))

Not applicable

Thanks for that.

What if I have a specific value of a field for which I want to see ranges for only

e.g. I only want to apply a range to Gross Margin and not Net Marging.

P&L_Line> Gross Margin

P&L_Line > Net Margin

Would I then simply need to do a set analysis expression on my front end to get the ranges I need? Or will the range me added to all the P&L Lines?


You can go with class function

class( var,10 ) with var = 23 returns '20<=x<30'

class( var,5,'value' ) with var = 23 returns '20<= value <25'

class( var,10,'x',5 ) with var = 23 returns '15<=x<25'

For eg:

Class(GrossMarigin,10) in dimension



There is a very cool function that you can use during the loading process that is called IntervalMatch. Here is an exerpt of the QlikView help (F1), I invite you to look-up the rest of the information for practical examples.



The IntervalMatch prefix is used to create a table matching discrete numeric values to one or more numeric intervals.

It must be placed before a Load or Select (SQL) statement that loads the intervals. The field containing the discrete data points (Time in the example below) must already have been loaded into QlikView before the statement with the IntervalMatch prefix. The prefix does not by itself read this field from the database table. The prefix transforms the loaded table of intervals to a table that contains an additional column: the discrete numeric data points. It also expands the number of records so that the new table has one record per possible combination of discrete data point and interval.

The intervals may be overlapping and the discrete values will be linked to all matching intervals.

The general syntax is:

IntervalMatch (matchfield) (loadstatement | selectstatement )

matchfield is the field containing the discrete numeric values to be linked to intervals.

loadstatement or selectstatement must result in a two-column table, where the first field contains the lower limit of each interval and the second field contains the upper limit of each interval. The intervals are always closed, i.e. the end points are included in the interval. Non-numeric limits render the interval to be disregarded (undefined).

There is also an extended syntax of IntervalMatch including one or several additional key fields. See IntervalMatch (Extended Syntax).

Creator II
Creator II

Iam also getting same issue. But ranges are not working in Scatter chart. Is any body have solution, Please send chart image.