def string_to_number(df, column):
    """
    Convert string into float
    :param df: dataframe to convert
    :param column: column index to convert
    :return: converted dataframe
    """
    # Check if first value (0) of the column (column) is a string
    if isinstance(df.iloc[0, df.columns.get_loc(column)], str):
        # Replace comma with an empty
        df[column] = df[column].str.replace(",", "")
        # Convert string into float
        df[column] = df[column].astype(float)
    # return converted dataframe
    return df