In this tutorial you will learn how to add conditional formatting to your 3DBI models in Microsoft® Power BI®. With conditional formatting you can specify customized object colors, including color gradients, based on field values. You can apply conditional formatting to any 3D object, as long as you base the formatting on a field that has numeric, color name or hex code, or web URL value. Conditional formatting support is added to the 3DBI visual version 2.4.
But first, what is 3DBI?
3DBI is a custom visual we created for Power BI that will allow you to bring various types of 3D models directly into Power BI. Typical industries making use of 3DBI are property management, facility management, warehouse management, building information management, or just about any industry where you deal with information about physical objects in a physical world. The following tutorials can provide more in depth information on how to create these models yourself:
To illustrate the purpose of conditional formatting we have created a 3DBI model of a warehousing containing roughly 30.000 bin locations. Also, our dataset contains a column that specifies per bin location what the fill rate is of that location, going from 0 to 100%. We will be using that field to colorize all objects with a gradient color.
1 – Default colors
3DBI models contain color information about each object. By default, it is that color that is given to all objects in the 3D view.
2 – Overwriting Colors
To indicaticate that you want to overwrite the default colors that come with the model, you must assign a category to the Color By field. Ideally that category should only contain 1 single entry because only 1 conditional color can be given to the 3DBI visual. In case you data does not contain a column with a static value for all rows you can create a new one in the Data tab in Power BI.
Right after assigning a value to the Color By field all colors in your model will be overwritten with a custom definable static color.
3 – Define gradients
The final step is to apply conditional formatting to the Data Color in the 3DBI visual’s property pane.
Every object in your 3D model will now receive a color that is calculated by Power BI, based on the conditions you defined.