Creating flattened tables in Power Query for ML in Power BI
Now that you’ve done some analysis and discovered features that you’d like to include for your first round of ML models, you return to Power Query and get to work. You review your notes from the previous sections of this chapter and begin with the Predict Damage table in the ML Queries group.
Modifying the Predict Damage table in Power Query
Since a row will represent an individual event that is predicted, you do not need to do any groupings with the data. You will be selecting columns and filtering down the rows to a set of data that is better suited to the task:
- Highlight the Predict Damage table in the ML Queries group.
- The aircraft class code for airplane is
A
, so filter the Aircraft Class Code column toA
. - Filter the Incident Date column to be on or after
1/1/2014
. - On the Power Query ribbon, select Home | Manage Columns | Choose Columns and keep the Size and Indicated Damage...