Use the get_data() function to retrieve the datas after auto data preparation. This function returns a dictionary of DataFrames containing the data after auto data preparation.
This function uses no parameters.
Example setup
- Get the connection to the database to execute the function.
- You must import the required functions mentioned in the example from teradataml
- The function returns an error if not supported on the database you are connected to.
Load the example data.
>>> load_example_data("teradataml", "titanic")
Create teradataml DataFrames.
>>> titanic = DataFrame.from_table("titanic")
Example 1: Run AutoDataPrep for classification problem
Titanic dataset is used to predict the survival of passengers.
Create an instance of AutoDataPrep.
>>> aprep_obj = AutoDataPrep(task_type="Classification", verbose=2)
Fit the data.
>>> aprep_obj.fit(titanic, titanic.survived)
Retrieve the data after auto data preparation.
>>> datas = aprep_obj.get_data()