Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

need reference lines for 0 line value in chart??? how do we do it?? need help please.

Hi all,

I have a graph as shown in the file attached.I need a horizontal line representing the '0' of y axis and also where ever the graph cuts the zero line I need vertical lines representing the corresponding x axis values.

Is this possible.Please require help.

I have attached my qv file as well s the image to clarify the requirement.

27 Replies
Not applicable
Author

Hi thanks for the response.

This has been done manually by checking out where the lines meet and give the corresponding strik_price1.So can this be done without we specifying the value???because as you can see at 76 its wrong it doesn't cross the graph here at zero.

Jason_Michaelides
Partner - Master II
Partner - Master II

As I mentioned above, the maths to calculate the intersect of a curved line like this is pretty complex. Our resident genius/geek/OCD-guy Martin Mahler has solved this with a very long expression...!! He'll post it shortly!

simondachstr
Specialist III
Specialist III

Something like this maybe?

Not applicable
Author

oh my God!!!!

Martin your a genius.!!!!!!!!!!!!!!!

thanks a lotttttttttt it works

Not applicable
Author

Awesome Martin

Not applicable
Author

Hi Martin,

I have done few editing in the  expression keeping the same concept how ever you had solved,but not able to get the correct lines.Please can you look into this and help me out one more time.... please?????????????????????

Not applicable
Author

Hi Martin,

In the solution you provided on friday,for few conditions the ref lines are not working please can you help me out checking that why it doesn't happen for these options.

I have selected the conditions for which it is not showing the reference lines.Please check in the file attached.

simondachstr
Specialist III
Specialist III

The function I provided to you gives you the reference lines if your callput/strikeprice curve is a positive parable. The selection you made is a negative parable. A quick fix would be to add 2 additional reference lines with the same formulas, but max<>min and above<>below switched up.

Try it yourself first - I will only have time this evening to fix it.

simondachstr
Specialist III
Specialist III

That was quicker to fix than expected - see attached and let me know.

Not applicable
Author

Hi ,

Thanks a lot Martin,for your precious time and response .

Yes ,this helped.So by replacing '>0' it works right ?? ok, new learning for me .

I was actually changing the min/max and above/below as well which dint work..

Actually I have another doubt which I have attached above,anyways I will attach it again here,ones you become free please help me out.

Its the same but my net expression is different which has to be taken to get these reference line exp.I am trying it out,but somewhere its going wrong in the replacements .

Please help ones your free,till then I will try out and wish I solve it.