DP-500 · Question #74
You need to create a measure to count orders for the market basket analysis. How should you complete the DAX expression? To answer, select the appropriate options in the answer area.
This question tests your ability to write a DAX measure using COUNTROWS or DISTINCTCOUNT to count orders for use in market basket analysis in Power BI.
Question
Explanation
This question tests your ability to write a DAX measure using COUNTROWS or DISTINCTCOUNT to count orders for use in market basket analysis in Power BI.
Approach. The correct DAX measure for counting orders in market basket analysis typically uses COUNTROWS(Orders) or DISTINCTCOUNT(Orders[OrderID]) depending on whether you want total row count or unique order count. For market basket analysis specifically, you want distinct orders, so the expression would be: Order Count = DISTINCTCOUNT(Orders[OrderID]). This ensures each order is counted once regardless of how many line items it contains, which is essential for accurate basket frequency calculations.
Concept tested. Writing DAX measures using COUNTROWS or DISTINCTCOUNT to aggregate order data for market basket analysis in Power BI, understanding the difference between counting rows versus counting distinct values.
Reference. Microsoft Learn – DAX DISTINCTCOUNT function; Power BI market basket analysis documentation
Topics
Community Discussion
No community discussion yet for this question.