Power BI

Year-To-Date value with Power BI and DAX

How to calculate a year-to-date value of the sales in DAX with Power BI? Also called YTD, it represents the total to date of a given measure. For example, to calculate the year-to-date sales total with a DAX formula, use the built-in function called TOTALYTD. From this example, easily copy and paste the code and adjust it to the data analysis and reporting requirements.