models/train_classifier.py
def tcolumn(dataframe, col, dtype):
    """The tcolumn function changes the dtype of dataframe column(s)
 
    Args: 
        dataframe (DataFrame): the DataFrame for data_wrangling
        col (list): list for features to select from the DataFrame
        dtype (str): dtype to change to
 
 
    Returns: 
        dataframe (DataFrame): The DataFrame for analysis
 
    """
    for ele in col:
        dataframe.loc[:, ele] = dataframe.loc[:, ele].astype(dtype)

    return dataframe
The tcolumn function changes the dtype of dataframe column(s)
 
    Args: 
        dataframe (DataFrame): the DataFrame for data_wrangling
        col (list): list for features to select from the DataFrame
        dtype (str): dtype to change to
 
 
    Returns: 
        dataframe (DataFrame): The DataFrame for analysis
 
    
The tcolumn function changes the dtype of dataframe column(s)
The tcolumn function changes the dtype of dataframe column ( s )
def tcolumn(dataframe, col, dtype):
    for ele in col:
        dataframe.loc[:, ele] = dataframe.loc[:, ele].astype(dtype)
    return dataframe
def tcolumn ( dataframe , col , dtype ) : for ele in col : dataframe . loc [ : , ele ] = dataframe . loc [ : , ele ] . astype ( dtype ) return dataframe
The tcolumn function changes the dtype of dataframe column(s)
The tcolumn function changes the dtype of dataframe column ( s )
"""The tcolumn function changes the dtype of dataframe column(s)
 
    Args: 
        dataframe (DataFrame): the DataFrame for data_wrangling
        col (list): list for features to select from the DataFrame
        dtype (str): dtype to change to
 
 
    Returns: 
        dataframe (DataFrame): The DataFrame for analysis
 
    """
dataframe (DataFrame): The DataFrame for analysis
dataframe ( DataFrame ) : The DataFrame for analysis
dataframe
the DataFrame for data_wrangling
the DataFrame for data_wrangling
col
list for features to select from the DataFrame
list for features to select from the DataFrame
dtype
dtype to change to
dtype to change to