Forum Discussion
MKPartner
3 years agoHelper II
Calculated TREND line but wrong displayed X axis
Hello Team, I trying to show trend line on my graphs using tweak linear regresion DAX code as below: Score Trend =
VAR Known =
FILTER (
SELECTCOLUMNS (
ALLSELECTED...
- 3 years ago
Hi MKPartner
Do you use Month End Date column on X axis? If so, it will move one month right to the next month because Power BI will adjust the axis display values automatically according to the width of the visual. As the month end date is near the start date of next month, it moves to the next month.
To avoid this, it is recommended to use a date column like Month Start date on the axis. Based on your current DAX, you can try
WC_Month = EOMONTH('COQ Calendar'[Year] & " " & 'COQ Calendar'[Month_2],-1) + 1Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
MKPartner
3 years agoHelper II
Thank you for your help.
I did the same ba changing EOMONTH function to EDATE function.
WC_Month = EDATE('COQ Calendar'[Year] & " " & 'COQ Calendar'[Month_2],0)