12. Data Hierarchies and Groups
12.6 Bin Groups (Numeric and Date Bins)
Bins turn a numeric or date column into equal-sized ranges. They are perfect for histograms.
Steps in Power BI – delivery time bins
- Right-click Orders › Delivery Time Mins › New group.
- Group type: Bin. The dialog shows the Min value and Max value of the column.
- Bin type: Size of bins › Bin size
5› OK. A field Delivery Time Mins (bins) appears with values 0, 5, 10, 15 … (each is the start of a range: 5 = 5–9.99 minutes). - Build a clustered column chart: X-axis = Delivery Time Mins (bins), Y-axis = Total Orders. Set the X-axis Type to Categorical if you want every bin labelled.
- Order value bins: right-click Orders › Amount › New group › Bin › Size of bins
100→ ₹0–99, ₹100–199 … - Number of bins: choose Bin type Number of bins ›
10. Power BI calculates the size from the min and max. This is quick for exploration, but the edges are odd numbers. - Date columns can also be binned (for example by 7 days).
Ravindra Bagale's Tip
Friends, don't make a mistake here: bins are fixed from the column values, and outliers stretch the range, so one 500-minute delivery creates many empty bins. Clean outliers first. Also check the grain: for order-value bins, bin an order-level value, not the per-line Amount. This matters for both exams and interviews.
Ravindra Bagale's Tip – मराठी
मित्रांनो, इथे चूक करू नका: bins column च्या values वरून fixed होतात, आणि outliers range ताणतात, त्यामुळे एकच 500-minute delivery अनेक रिकामे bins तयार करते. आधी outliers साफ करा. Grain पण तपासा: order-value bins साठी order-level value चे bins करा, प्रत्येक line चा Amount नाही. हे exam आणि interview दोन्हीसाठी important आहे.
Ravindra Bagale's Tip – हिंदी
दोस्तों, यहाँ गलती मत करना: bins column की values से fixed होते हैं, और outliers range को खींच देते हैं, इसलिए एक 500-minute delivery कई ख़ाली bins बना देती है. पहले outliers साफ़ करो. Grain भी check करो: order-value bins के लिए order-level value के bins बनाओ, हर line का Amount नहीं. यह exam और interview दोनों के लिए ज़रूरी है.
Practice task
Create bins of 5 minutes for Delivery Time Mins and ₹100 for Amount. Build two histograms and a slicer on Platform to compare Blinkit and Amazon Now distributions.