The lineage as a tidy data frame.
Lineage.summary(include_removed=False)
Columns name, dtype, roles, source, sparse: one row per live column, in data frame order. dtype is the dtype category ("float", "int", "str", "categorical_unordered", …) and roles is the sorted role set joined with ", ".
The result is always a polars DataFrame, whatever backend the recipe was fitted on.
This is the same table FittedRecipe.summary returns for the live columns. Reach for it when you also want the removed columns (include_removed=True) and which step dropped each; use parents and ancestors to trace a single column.
Parameters
include_removed: bool = False
-
If
True, append a row for each removed column (in removal order) and add two columns: parents, the immediate parent columns joined with ", ", and removed_by, the id of the step that dropped the column (null for live columns). Default False.
Examples
One row per live column, mixing the normalized numerics (source "original", now float) with the dummy indicators (source "dummy"):
shape: (23, 5)| name | dtype | roles | source | sparse |
|---|
| str | str | str | str | bool |
| "Status" | "str" | "target" | "original" | false |
| "Seniority" | "float" | "feature" | "original" | false |
| "Time" | "float" | "feature" | "original" | false |
| "Age" | "float" | "feature" | "original" | false |
| "Expenses" | "float" | "feature" | "original" | false |
| … | … | … | … | … |
| "Marital_widow" | "float" | "feature" | "dummy" | false |
| "Records_yes" | "int" | "feature" | "dummy" | false |
| "Job_freelance" | "float" | "feature" | "dummy" | false |
| "Job_others" | "float" | "feature" | "dummy" | false |
| "Job_partime" | "float" | "feature" | "dummy" | false |
With include_removed=True the dropped categoricals appear too, along with each column’s parents:
lineage.summary(include_removed=True)
shape: (27, 7)| name | dtype | roles | source | sparse | parents | removed_by |
|---|
| str | str | str | str | bool | str | str |
| "Status" | "str" | "target" | "original" | false | "" | null |
| "Seniority" | "float" | "feature" | "original" | false | "" | null |
| "Time" | "float" | "feature" | "original" | false | "" | null |
| "Age" | "float" | "feature" | "original" | false | "" | null |
| "Expenses" | "float" | "feature" | "original" | false | "" | null |
| … | … | … | … | … | … | … |
| "Job_partime" | "float" | "feature" | "dummy" | false | "Job" | null |
| "Home" | "str" | "feature" | "original" | false | "" | "dummy" |
| "Marital" | "str" | "feature" | "original" | false | "" | "dummy" |
| "Records" | "str" | "feature" | "original" | false | "" | "dummy" |
| "Job" | "str" | "feature" | "original" | false | "" | "dummy" |