Forum Discussion

Deemo's avatar
Deemo
Advocate II
6 years ago

Calculate trend value using linear regression

Hi All,

 

I have a requirement to calculate trend(which will be shown as Up and Down arrow) using linear regression based on filters selected in the report including date range, region and other filters.

BBelow are the examples.

 

Eample 1: 

DateTotal
3/26/202010
3/27/202023
3/28/202030
3/29/202060
3/30/202030
3/31/2020240
4/1/202080

 

As per Linear regression in excel, Trend is positive and going up. Hence, Trend which I have to show will be an up arrow.

 
 

 

Example 2:

DateTotal
3/26/202040
3/27/202044
3/28/202034
3/29/202050
3/30/202040
3/31/202022
4/1/202021

 

Since the trend is going down, I have to show final trend as down arrow.

 

Thanks in advance!

 

 

5 Replies