4 Replies Latest reply on Jul 31, 2013 6:37 PM by Scott Tennican

# Is it possible to save trend line statistics to use in a calculation?

I want to be able to save the slope that is given after creating a trend line and use it in a calculation.

Ex:

Individual trend lines:

 Panes Line Coefficients Row Column p-value DF Term Value StdErr t-value p-value Order Line Value Quantity Ordered < 0.0001 202 Quantity Ordered 13.7333 0.521502 26.3342 < 0.0001 intercept -12849.5 17165.8 -0.748553 0.454997

This is an example of what the output from the trend line would look like.  I want to save 13.7333 and use it in a new calculation.

• ###### 1. Re: Is it possible to save trend line statistics to use in a calculation?

Probably not (unless Jonathan has cracked this particular nut). Tableau doesn't generally tend to give us access to under-the-cover calcs, variables (Measure Name/Values come to mind) or formulas. But create the trend yourself and it's yours so you have complete access.

Cheers,

--Shawn

• ###### 2. Re: Is it possible to save trend line statistics to use in a calculation?

I've never known of any way to pull the trend lines out. The are one of the last things to be computed, so that's my guess as to why they aren't available in other calculations.

• ###### 3. Re: Is it possible to save trend line statistics to use in a calculation?

Thanks guys!  I didn't think there was a way but I figured if anyone had figured it out it I would know from posting on the forum.

• ###### 4. Re: Is it possible to save trend line statistics to use in a calculation?

Yes, Jonathan is right.

Trend lines are computed after the result table is computed, possibly pivoted for measure names/values and partitioned into Panes. The fields that you can manipulate in Tableau are in the result table. After the result table is visualized, trend lines are drawn on top and reference lines are drawn on top of that. The summary tab in a View Data window shows roughly what is in the result table.

1 of 1 people found this helpful