Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have created a Linestx dax as -
Solved! Go to Solution.
@Ethanhunt123 , Try using below
TempTable =
VAR line =
LINESTX (
ALLSELECTED('Sales order line fact'[Order month]), -- This respects the slicer
[Total revenue trend],
'Sales order line fact'[Order month]
)
VAR slope = SELECTCOLUMNS(line, [Slope1])
VAR intercept = SELECTCOLUMNS(line, [Intercept])
RETURN
ADDCOLUMNS(
SUMMARIZE(
'Sales order line fact',
'Sales order line fact'[Order month]
),
"Slope", slope,
"Intercept", intercept,
"Revenue Trend", 'Sales order line fact'[Order month] * slope + intercept
)
Proud to be a Super User! |
|
@Ethanhunt123 , Try using below
TempTable =
VAR line =
LINESTX (
ALLSELECTED('Sales order line fact'[Order month]), -- This respects the slicer
[Total revenue trend],
'Sales order line fact'[Order month]
)
VAR slope = SELECTCOLUMNS(line, [Slope1])
VAR intercept = SELECTCOLUMNS(line, [Intercept])
RETURN
ADDCOLUMNS(
SUMMARIZE(
'Sales order line fact',
'Sales order line fact'[Order month]
),
"Slope", slope,
"Intercept", intercept,
"Revenue Trend", 'Sales order line fact'[Order month] * slope + intercept
)
Proud to be a Super User! |
|
User | Count |
---|---|
25 | |
12 | |
8 | |
6 | |
6 |
User | Count |
---|---|
26 | |
12 | |
11 | |
9 | |
6 |