Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

acbishop2
Contributor

Specify Minimum for X-Axis

Hello All,

I have a bar graph that displays days between marketing and response. I made the x-axis continuous because I want to show gaps if there are any. Regardless of the filters, I need my graph to start at 0. Here's what my graph looks like without filters:

Help1.JPG

The problem happens when I use a filter to look at specific marketing methods. For example, in the chart below, responses start coming in after 12 days, therefore setting the x-axis minimum to 12.

Help2.JPG

Any ideas? As always, I appreciate the help!

1 Solution

Accepted Solutions
mikaelsc
Contributor III

Re: Specify Minimum for X-Axis

Count([Marketing Effort])+0*Count({1<DeltaDate={"<=$(=max(DeltaDate)) "}>}[Marketing Effort])

(i obviously created the delta date field in the script -- use it as dimension as well... it's cleaner

10 Replies
isingh30
Contributor III

Re: Specify Minimum for X-Axis

Can you share your data or sample application?

Thanks.

vvira1316
Valued Contributor II

Re: Specify Minimum for X-Axis

You may want to set Static Min to 0. refer to following link, not exactly same situation but will help in understanding.

Force 0 check box may also help

Data Point Value is not completely visible in a Bar Chart with a Log Scale

acbishop2
Contributor

Re: Specify Minimum for X-Axis

Here's some (very) simplified sample data, as well as a sample app. Notice how when you select certain marketing efforts with the filter, the x-axis minimum changes.

acbishop2
Contributor

Re: Specify Minimum for X-Axis

Thanks for the response, Vijay, but I'm needing help with Qlik Sense, not QlikView. ...unless there is a hidden static min box that I'm just not seeing...

acbishop2
Contributor

Re: Specify Minimum for X-Axis

Ishtdeep,

I still haven't been able to figure this out. Can you take a look at it again? I added the data above.

digvijay‌, you've been able to help me with problems like this before. Is this possible?

acbishop2
Contributor

Re: Specify Minimum for X-Axis

This is what I feared. Thanks for confirming.

mikaelsc
Contributor III

Re: Specify Minimum for X-Axis

adapt your measure? Count([Marketing Effort])+0*Count({1}[Marketing Effort])

acbishop2
Contributor

Re: Specify Minimum for X-Axis

Mikael,

You're a genius. This definitely works for the problem I posed, but it brings up one more issue: this creates both a static minimum and a static maximum (which I don't want). Is there any way to make it so that the static minimum is set to 0 but the maximum changes depending on the data displayed (affected by the filter chosen)?

mikaelsc
Contributor III

Re: Specify Minimum for X-Axis

Count([Marketing Effort])+0*Count({1<DeltaDate={"<=$(=max(DeltaDate)) "}>}[Marketing Effort])

(i obviously created the delta date field in the script -- use it as dimension as well... it's cleaner

Community Browser