Question: Using scikit - learn, create a custom transformer called Assignment 3 Transformer. Include an input parameter called create _ new _ column with a default

Using scikit-learn, create a custom transformer called Assignment3Transformer. Include an input parameter called create_new_column with a default value of True that performs Step 1 when its value is True, but skips Step 1 and just returns the DataFrame when its value False.
Step 1 adds an attribute to the end of the numerical data (i.e. new last column) that is the result of the days_per_week column multiplied by the hours_per_day column. It also deletes the days_per_week and hours_per_day columns.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!