Teradata Package for Python Function Reference on VantageCloud Lake - fit - Teradata Package for Python - Look here for syntax, methods and examples for the functions included in the Teradata Package for Python.

Teradata® Package for Python Function Reference on VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Package for Python
Release Number
20.00.00.08
Published
November 2025
ft:locale
en-US
ft:lastEdition
2025-12-05
dita:id
TeradataPython_FxRef_Lake_2000
Product Category
Teradata Vantage
teradataml.automl.AutoChurn.fit = fit(self, data, target_column=None, id_column='automl_id')
DESCRIPTION:
    Function triggers the AutoML run. It is designed to handle regression , 
    classification and clustering tasks depending on the specified "task_type".
 
PARAMETERS:
    data:
        Required Argument.
        Specifies the input teradataml DataFrame.
        Types: teradataml Dataframe
    
    target_column:
        Required Argument. Optional only for clustering tasks.
        Specifies target column of dataset.
        Types: str or ColumnExpression
    
    id_column:
        Optional Argument.
        Specifies the unique identifier column in the dataset. By default, function
        internally creates a unique id column 'automl_id' if "id_column" is 
        not provided.
        Default Value: "automl_id"
        Types: str or ColumnExpression
 
RETURNS:
    None
 
RAISES:
    TeradataMlException, TypeError, ValueError
    
EXAMPLES:
    # Create an instance of the AutoML called "automl_obj" by referring 
    # "AutoML()" or "AutoRegressor()" or "AutoClassifier()" or 
    # "AutoFraud()" or "AutoChurn()" or "AutoCluster()" method.
    # Perform fit() operation on the "automl_obj".
 
    # Example 1: Fit AutoML by passing column expression for target column.
    >>> automl_obj.fit(data = housing_train, target_col = housing_train.price)
 
    # Example 2: Fit AutoML by passing name of target column.
    >>> automl_obj.fit(data = housing_train, target_col = "price")
 
    # Example 3: Fit fraud detection model on payment_fraud_df.
    >>> automl_obj.fit(data=payment_fraud_df, target_column="isFraud")
 
    # Example 4: Fit churn prediction model on churn_df.
    >>> automl_obj.fit(data=churn_df, target_column="churn")
 
    # Example 5: Passing clustering data for training, 
    # without specifying target column.
    >>> automl_obj.fit(data = bank_train)
 
    # Example 6: Fit AutoML by passing id column.
    >>> automl_obj.fit(admissions_train, "admitted", id_column="id")