Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

polynomial trend line

Hello,

How can I do a second or third degree polynomial trend line?

I only have found the linest_m and linest_b function to calculate a linear trend line,

Regards

5 Replies
johnw
Champion III
Champion III

On the Expressions tab, there is a Trendlines section, allowing average, linear, polynomial of 2nd to 4th degree, and exponential. You shouldn't need to calculate it at all.

Now, sometimes it IS still useful to calculate your own trend line. I often do. But I am not aware of any QlikView functions that directly support polynomial trend lines. There's probably a way to do it using the actual definitions of these trend lines in some way, but I wouldn't expect it to be easy. So hopefully one of the supplied trend lines will serve the need.

Not applicable
Author

Hello John,

I had seen this section, but it's only avaliable for graphs and I'm working with boards...

Anonymous
Not applicable
Author

You need to "reverse engineer" the formula you're trying to trend, then re-assemble it.

Here and example of my Exponential Trend Line formula:

=Exp(LINEST_M(TOTAL AGGR( Log(Sum([Result])) ),[Period]),[Period])*[Period])

  *

  Exp(LINEST_B(TOTAL AGGR( Log(Sum([Result])) ),[Period]),[Period]))

This produces the formula y=b*e^(m*x) -- this is the formula for "Trendlines: Exponential" in Qlikview's Chart Properties, Expressions tab.

(note: [Result]=y, and [Period]=x in my example above)

You can mirror this for just about any trendline/formula you need (although I imagine polynomials could get complicated quickly).

MA1
Contributor III
Contributor III

Hi, Eric

Could you please help me?

I try to build this trend lines   - ax^2 + bx+c.

Maybe do you have any example ?


Any ideas?

richbyard
Contributor III
Contributor III

Calculating trend lines, values and formulas on charts and tables in Qlik Sense

I'm still working on the polynomial lines... They're not quite so straighforward...