Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
Coming your way, the Qlik Data Revolution Virtual Summit. October 27-29. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator
Creator

Count of items lying in each quadrant in a scatter plot

Hi Guys,

 

I have created a scatter plot based on Stores and the sales by the each store. I would like to know the count of stores that lie in each quadrant. Is this possible? Please let me know.

Best Regards,

Rony

1 Solution

Accepted Solutions
Highlighted
Creator
Creator

Okay my bad again, in my original reply I had the $(= but they shouldn't be there so you can remove them

Count({<Location= 
{"=((Sum({$<Year={'2019'}>}Value)/Sum({$<Year={'2019'}>}Volume))/(Sum({$<Year={'2018'}>}Value)/Sum({$<Year={'2018'}>}Volume))-1)<=0"}
>*<Location= 
{"=(Sum({$<Year={'2019'}>}Volume)/Sum({$<Year={'2018'}>}Volume)-1)<=0"}>} 
distinct Location)

How is this? 

View solution in original post

17 Replies
Highlighted
Creator II
Creator II

Hi

I suppose you put right reference lines

you can use set analysis filters on measures

Capturar.PNG

A
Count({<Agrupamento={"=sum(Valor)<=17000"}>*<Agrupamento={"=count(Valor)<=32"}>} distinct Agrupamento)

B
Count({<Agrupamento={"=sum(Valor)<=17000"}>*<Agrupamento={"=count(Valor)>32"}>} distinct Agrupamento)

C
Count({<Agrupamento={"=sum(Valor)>17000"}>*<Agrupamento={"=count(Valor)<=32"}>} distinct Agrupamento)

D
Count({<Agrupamento={"=sum(Valor)>17000"}>*<Agrupamento={"=count(Valor)>32"}>} distinct Agrupamento)

 

Regards

 

YoshidaQlik https://www.youtube.com/channel/UC1I9P8MqCZEhB6Nw3FdSqng
Highlighted
Creator
Creator

Hi Yoshida,

 

What do you mean by Agrupamento? Could you explain this expression to me?

 

Best Regards,

Rony

Highlighted
Creator
Creator

Could you post a screenshot of your scatter graph?

What are the axes? Sales and what?

Highlighted
Creator II
Creator II

Hi,

In fact, I had forgotten to translate the formula,

Agrupamento would be your Stores

Valor would be the sales or whatever measure you want to put in the chart

 

Regards

YoshidaQlik https://www.youtube.com/channel/UC1I9P8MqCZEhB6Nw3FdSqng
Highlighted
Creator
Creator

Yes. X axis is the growth in Average Selling Price and Y axis is the Volume growth. Attached is the screenshot.

Highlighted
Creator
Creator

Okay, then use Yoshidaqlik's solution but change the values to your corresponding values

Count({<Store={"=avg(sellingprice)<=0"}>*<Store={"=avg(volumegrowth)<=0"}>} distinct Store)

 

I don't know what expressions you used to calculate the selling prices and volume growths, but put them in the above expressions.

Highlighted
Creator
Creator

ok. Thanks Anseg and Yoshida. I'll try this and get back.

 

Rony

Highlighted
Creator
Creator

Hi Guys,

 

The horizontal line represents ASP growth and vertical line represent Volume growth. I have taken store name as dimension. Formula for ASP growth used is, ((Sum({$<Year={"2019"}>}ASP))/(Sum({$<Year={"2018"}>}ASP)))-1 and volume growth is ((Sum({$<Year={"2019"}>}Volume))/Sum({$<Year={"2018"}>}Volume)))-1. Please guide me with respect to the complete expression.

 

Best Regards,

Rony

Highlighted
Creator
Creator

Hi,

Does this work?

Count({<Store=
{"=$(((avg({$<Year={'2019'}>}ASP))/(avg({$<Year={'2018'}>}ASP)))-1)<=0"}
>*<Store=
{"=$(((avg({$<Year={'2019'}>}Volume))/(avg({$<Year={'2018'}>}Volume)))-1)<=0"}
distinct Store)